mirror of
https://github.com/OneUptime/oneuptime.git
synced 2026-04-06 00:32:12 +02:00
- Implement tests for ResourceCommands, ConfigCommands, UtilityCommands, and ErrorHandler. - Enhance test coverage for command registration and execution, including list, get, create, update, delete, and count operations. - Introduce tests for credential management and context handling in commands. - Add error handling tests to ensure graceful exits on API errors and invalid inputs. - Update jest configuration to exclude test files from coverage and adjust TypeScript settings.
36 lines
989 B
JSON
36 lines
989 B
JSON
{
|
|
"preset": "ts-jest",
|
|
"testEnvironment": "node",
|
|
"testMatch": ["**/__tests__/**/*.ts", "**/?(*.)+(spec|test).ts"],
|
|
"collectCoverageFrom": [
|
|
"**/*.ts",
|
|
"!**/*.d.ts",
|
|
"!**/node_modules/**",
|
|
"!**/build/**",
|
|
"!**/Tests/**",
|
|
"!Index.ts"
|
|
],
|
|
"setupFilesAfterEnv": [],
|
|
"testTimeout": 30000,
|
|
"modulePathIgnorePatterns": ["<rootDir>/build/"],
|
|
"moduleNameMapper": {
|
|
"^Common/(.*)$": "<rootDir>/../Common/$1"
|
|
},
|
|
"transformIgnorePatterns": [
|
|
"node_modules/(?!(@oneuptime)/)"
|
|
],
|
|
"transform": {
|
|
"^.+\\.ts$": ["ts-jest", {
|
|
"tsconfig": {
|
|
"noUnusedLocals": false,
|
|
"noUnusedParameters": false,
|
|
"strict": false,
|
|
"noImplicitAny": false,
|
|
"noImplicitThis": false,
|
|
"noPropertyAccessFromIndexSignature": false,
|
|
"module": "commonjs"
|
|
}
|
|
}]
|
|
}
|
|
}
|