forked from callumalpass/tasknotes
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjest.integration.config.js
More file actions
31 lines (31 loc) · 983 Bytes
/
jest.integration.config.js
File metadata and controls
31 lines (31 loc) · 983 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
module.exports = {
preset: 'ts-jest',
testEnvironment: 'jsdom',
displayName: 'Integration Tests',
roots: ['<rootDir>/tests/integration'],
testMatch: [
'**/integration/**/*.test.ts'
],
transform: {
'^.+\\.ts$': 'ts-jest',
},
setupFilesAfterEnv: ['<rootDir>/tests/test-setup.ts'],
moduleNameMapper: {
// Only mock Obsidian and UI libraries - use real date/parsing libraries
'^obsidian$': '<rootDir>/tests/__mocks__/obsidian.ts',
'^@fullcalendar/(.*)$': '<rootDir>/tests/__mocks__/fullcalendar.ts',
'^yaml$': '<rootDir>/tests/__mocks__/yaml.ts'
// chrono-node, rrule, ical.js, date-fns will use real implementations
},
// Integration tests may need more time for complex workflows
testTimeout: 30000,
clearMocks: true,
restoreMocks: true,
// Less strict coverage for integration tests (focus on workflow completion)
collectCoverageFrom: [
'src/**/*.ts',
'!src/**/*.d.ts',
'!src/main.ts',
'!tests/**/*'
]
};