let ts-jest transform JS and allow JS in tests
Signed-off-by: CrazyMax <1951866+crazy-max@users.noreply.github.com>
This commit is contained in:
@@ -38,7 +38,7 @@ module.exports = {
|
||||
setupFiles: ['dotenv/config'],
|
||||
testMatch: ['**/*.test.ts'],
|
||||
transform: {
|
||||
'^.+\\.ts$': [
|
||||
'^.+\\.[tj]s$': [
|
||||
'ts-jest',
|
||||
{
|
||||
useESM: true,
|
||||
@@ -46,7 +46,7 @@ module.exports = {
|
||||
}
|
||||
]
|
||||
},
|
||||
transformIgnorePatterns: ['/node_modules/(?!(?:@octokit|universal-user-agent)/)'],
|
||||
transformIgnorePatterns: ['/node_modules/(?!(?:@octokit|universal-user-agent|before-after-hook)/)'],
|
||||
moduleNameMapper: {
|
||||
'^(\\.{1,2}/.*)\\.js$': '$1'
|
||||
},
|
||||
|
||||
@@ -21,7 +21,7 @@ module.exports = {
|
||||
testMatch: ['**/*.test.itg.ts'],
|
||||
testTimeout: 1800000, // 30 minutes
|
||||
transform: {
|
||||
'^.+\\.ts$': [
|
||||
'^.+\\.[tj]s$': [
|
||||
'ts-jest',
|
||||
{
|
||||
useESM: true,
|
||||
@@ -29,7 +29,7 @@ module.exports = {
|
||||
}
|
||||
]
|
||||
},
|
||||
transformIgnorePatterns: ['/node_modules/(?!(?:@octokit|universal-user-agent)/)'],
|
||||
transformIgnorePatterns: ['/node_modules/(?!(?:@octokit|universal-user-agent|before-after-hook)/)'],
|
||||
moduleNameMapper: {
|
||||
'^(\\.{1,2}/.*)\\.js$': '$1'
|
||||
},
|
||||
|
||||
@@ -2,7 +2,8 @@
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"rootDir": ".",
|
||||
"noEmit": true
|
||||
"noEmit": true,
|
||||
"allowJs": true
|
||||
},
|
||||
"include": [
|
||||
"src/**/*.ts",
|
||||
|
||||
Reference in New Issue
Block a user