Skip to content

Commit 51c373b

Browse files
committed
Fix allOf generation; convert to TS
1 parent 432be86 commit 51c373b

File tree

12 files changed

+333
-1222
lines changed

12 files changed

+333
-1222
lines changed

jest.config.js

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -55,20 +55,17 @@ module.exports = {
5555
// globalTeardown: null,
5656

5757
// A set of global variables that need to be available in all test environments
58-
// globals: {},
58+
globals: {
59+
'ts-jest': {
60+
tsConfig: 'tsconfig.json',
61+
},
62+
},
5963

6064
// An array of directory names to be searched recursively up from the requiring module's location
61-
// moduleDirectories: [
62-
// "node_modules"
63-
// ],
65+
moduleDirectories: ['node_modules', 'src'],
6466

6567
// An array of file extensions your modules use
66-
// moduleFileExtensions: [
67-
// "js",
68-
// "json",
69-
// "jsx",
70-
// "node"
71-
// ],
68+
moduleFileExtensions: ['ts', 'tsx', 'js'],
7269

7370
// A map from regular expressions to module names that allow to stub out resources with a single module
7471
// moduleNameMapper: {},
@@ -124,7 +121,7 @@ module.exports = {
124121
// snapshotSerializers: [],
125122

126123
// The test environment that will be used for testing
127-
testEnvironment: "node",
124+
testEnvironment: 'node',
128125

129126
// Options that will be passed to the testEnvironment
130127
// testEnvironmentOptions: {},
@@ -133,10 +130,7 @@ module.exports = {
133130
// testLocationInResults: false,
134131

135132
// The glob patterns Jest uses to detect test files
136-
// testMatch: [
137-
// "**/__tests__/**/*.js?(x)",
138-
// "**/?(*.)+(spec|test).js?(x)"
139-
// ],
133+
testMatch: ['**/tests/*.test.ts'],
140134

141135
// An array of regexp pattern strings that are matched against all test paths, matched tests are skipped
142136
// testPathIgnorePatterns: [
@@ -159,7 +153,9 @@ module.exports = {
159153
// timers: "real",
160154

161155
// A map from regular expressions to paths to transformers
162-
// transform: null,
156+
transform: {
157+
'^.+\\.(ts|tsx)$': 'ts-jest',
158+
},
163159

164160
// An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation
165161
// transformIgnorePatterns: [

0 commit comments

Comments
 (0)