mirror of
https://github.com/Komediruzecki/token-circles.git
synced 2026-10-20 09:46:43 +02:00
Two major improvements: ### Error Handling Standardization - lib/errors.js: AppError class + asyncHandler wrapper - Centralized error middleware, ~186 try/catch blocks removed from 23 routes - Zod validation middleware for transactions - New repos: settingsRepo, usersRepo - 70 unit tests for baseRepo + loanCalculator ### Bill Calendar View - BillCalendar.tsx with monthly grid, popover, mark-paid - GET /api/bills/calendar endpoint - 7 E2E tests ### Testing: 458 E2E + 70 unit tests passing
31 lines
810 B
JavaScript
31 lines
810 B
JavaScript
module.exports = {
|
|
testEnvironment: 'node',
|
|
roots: ['<rootDir>'],
|
|
testMatch: ['**/test/unit/**/*.spec.js', '**/test/unit/**/*.test.js'],
|
|
collectCoverageFrom: [
|
|
'repositories/**/*.js',
|
|
'services/**/*.js',
|
|
'utils.js',
|
|
'routes/**/*.js',
|
|
'!node_modules/**',
|
|
'!index.js',
|
|
],
|
|
coverageDirectory: '<rootDir>/coverage',
|
|
coverageReporters: ['text', 'text-summary', 'lcov', 'html'],
|
|
// Ratchet up as coverage increases. Target: 60%+ across the board.
|
|
coverageThreshold: {
|
|
global: {
|
|
branches: 5,
|
|
functions: 5,
|
|
lines: 5,
|
|
statements: 5,
|
|
},
|
|
},
|
|
modulePaths: ['<rootDir>'],
|
|
moduleDirectories: ['node_modules', '<rootDir>'],
|
|
verbose: true,
|
|
moduleNameMapper: {
|
|
'\\.(css|less|scss|sass)$': '<rootDir>/../test/__mocks__/styleMock.js',
|
|
},
|
|
};
|