Skip to content
This repository was archived by the owner on Jan 26, 2019. It is now read-only.

Commit e1224ed

Browse files
author
nicolaserny
committed
Add tsconfig.test.json (instead of using deprecated TS_CONFIG)
1 parent 5028178 commit e1224ed

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

Diff for: packages/react-scripts/config/paths.js

+2
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@ module.exports = {
8282
testsSetup: resolveApp('src/setupTests.ts'),
8383
appNodeModules: resolveApp('node_modules'),
8484
appTsConfig: resolveApp('tsconfig.json'),
85+
appTsTestConfig: resolveApp('tsconfig.test.json'),
8586
publicUrl: getPublicUrl(resolveApp('package.json')),
8687
servedPath: getServedPath(resolveApp('package.json')),
8788
// These properties only exist before ejecting:
@@ -112,6 +113,7 @@ if (
112113
testsSetup: resolveOwn('template/src/setupTests.ts'),
113114
appNodeModules: resolveOwn('node_modules'),
114115
appTsConfig: resolveOwn('template/tsconfig.json'),
116+
appTsTestConfig: resolveOwn('template/tsconfig.test.json'),
115117
publicUrl: getPublicUrl(resolveOwn('package.json')),
116118
servedPath: getServedPath(resolveOwn('package.json')),
117119
// These properties only exist before ejecting:

Diff for: packages/react-scripts/scripts/utils/createJestConfig.js

+1-4
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,8 @@ module.exports = (resolve, rootDir) => {
4646
'^react-native$': 'react-native-web',
4747
},
4848
globals: {
49-
__TS_CONFIG__: {
50-
module: 'commonjs',
51-
},
5249
'ts-jest': {
53-
tsConfigFile: paths.appTsConfig,
50+
tsConfigFile: paths.appTsTestConfig,
5451
},
5552
},
5653
};

0 commit comments

Comments
 (0)