ts-jest 26.4.4 → 26.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.ts-jest-digest +1 -1
- package/CHANGELOG.md +14 -0
- package/dist/cli/config/init.js +3 -2
- package/dist/cli/config/migrate.js +3 -2
- package/dist/compiler/language-service.js +1 -1
- package/dist/config/config-set.d.ts +3 -1
- package/dist/config/config-set.js +38 -37
- package/dist/types.d.ts +3 -0
- package/package.json +3 -7
- package/website/.docusaurus/client-modules.js +8 -0
- package/website/.docusaurus/codeTranslations.json +1 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-babel-7-or-ts-md-4aa.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-contributing-md-4d5.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-contribution-md-416.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-debugging-md-2bc.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-e-2-e-testing-md-594.json +17 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-esm-support-md-ff2.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-installation-md-3b8.json +17 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-migration-md-295.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-ast-transformers-md-687.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-babel-config-md-16d.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-compiler-md-203.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-diagnostics-md-a47.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-isolated-modules-md-9c5.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-md-aeb.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-stringify-content-path-regex-md-763.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-tsconfig-md-c3b.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-use-esm-md-f08.json +12 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-paths-mapping-md-7f7.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-presets-md-02b.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-processing-md-eab.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-react-native-md-668.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-test-helpers-md-bf3.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-troubleshooting-md-9d9.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-version-checking-md-21a.json +21 -0
- package/website/.docusaurus/docusaurus-plugin-content-docs/default/version-current-metadata-prop-751.json +117 -0
- package/website/.docusaurus/docusaurus-plugin-debug/default/docusaurus-debug-all-content-673.json +530 -0
- package/website/.docusaurus/docusaurus.config.js +244 -0
- package/website/.docusaurus/globalData.json +124 -0
- package/website/.docusaurus/i18n.json +7 -0
- package/website/.docusaurus/registry.js +36 -0
- package/website/.docusaurus/routes.js +171 -0
- package/website/.docusaurus/routesChunkNames.json +124 -0
- package/website/.docusaurus/site-metadata.json +31 -0
package/.ts-jest-digest
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
8078ee424534cfcaad85082d51f4cdef2771e231
|
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
# [26.5.0](https://github.com/kulshekhar/ts-jest/compare/v26.5.0...v26.4.4) (2021-01-29)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* reduce size of `node_modules` when adding `ts-jest` ([#2309](https://github.com/kulshekhar/ts-jest/issues/2309)) ([6bf2e8a](https://github.com/kulshekhar/ts-jest/commit/b8d5d2090567f23947d9efd87f5f869b16bf2e8a))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* introduce `exclude` to exclude files from diagnostics ([#2308](https://github.com/kulshekhar/ts-jest/issues/2308)) ([cd82fd3](https://github.com/kulshekhar/ts-jest/commit/0c555c250774a7fd9e356cf20a3d8b693cd82fd3))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
1
15
|
## [26.4.4](https://github.com/kulshekhar/ts-jest/compare/v26.4.3...v26.4.4) (2020-11-08)
|
|
2
16
|
|
|
3
17
|
|
package/dist/cli/config/init.js
CHANGED
|
@@ -54,8 +54,9 @@ var path_1 = require("path");
|
|
|
54
54
|
var presets_1 = require("../helpers/presets");
|
|
55
55
|
exports.run = function (args) { return __awaiter(void 0, void 0, void 0, function () {
|
|
56
56
|
var file, filePath, name, isPackage, exists, pkgFile, hasPackage, _a, jestPreset, askedTsconfig, force, jsdom, tsconfig, pkgJson, jsFilesProcessor, shouldPostProcessWithBabel, preset, body, base, tsJestConf, content;
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
var _b, _c;
|
|
58
|
+
return __generator(this, function (_d) {
|
|
59
|
+
file = (_c = (_b = args._[0]) === null || _b === void 0 ? void 0 : _b.toString()) !== null && _c !== void 0 ? _c : 'jest.config.js';
|
|
59
60
|
filePath = path_1.join(process.cwd(), file);
|
|
60
61
|
name = path_1.basename(file);
|
|
61
62
|
isPackage = name === 'package.json';
|
|
@@ -66,9 +66,10 @@ var backports_1 = require("../../utils/backports");
|
|
|
66
66
|
var presets_1 = require("../helpers/presets");
|
|
67
67
|
exports.run = function (args) { return __awaiter(void 0, void 0, void 0, function () {
|
|
68
68
|
var nullLogger, file, filePath, footNotes, name, isPackage, actualConfig, migratedConfig, presetName, preset, jsTransformers, jsWithTs, jsWithBabel, presetValue, migratedValue, presetValue, migratedValue, before, after, stringify, prefix;
|
|
69
|
-
|
|
69
|
+
var _a;
|
|
70
|
+
return __generator(this, function (_b) {
|
|
70
71
|
nullLogger = bs_logger_1.createLogger({ targets: [] });
|
|
71
|
-
file = args._[0];
|
|
72
|
+
file = (_a = args._[0]) === null || _a === void 0 ? void 0 : _a.toString();
|
|
72
73
|
filePath = path_1.resolve(process.cwd(), file);
|
|
73
74
|
footNotes = [];
|
|
74
75
|
if (!fs_1.existsSync(filePath)) {
|
|
@@ -71,7 +71,7 @@ exports.initializeLanguageServiceInstance = void 0;
|
|
|
71
71
|
var bs_logger_1 = require("bs-logger");
|
|
72
72
|
var fs_1 = require("fs");
|
|
73
73
|
var path_1 = require("path");
|
|
74
|
-
var memoize = require("lodash
|
|
74
|
+
var memoize = require("lodash/memoize");
|
|
75
75
|
var mkdirp = require("mkdirp");
|
|
76
76
|
var constants_1 = require("../constants");
|
|
77
77
|
var messages_1 = require("../utils/messages");
|
|
@@ -3,6 +3,8 @@ import { Logger } from 'bs-logger';
|
|
|
3
3
|
import { CompilerOptions, CustomTransformers, Diagnostic, ParsedCommandLine } from 'typescript';
|
|
4
4
|
import type { TTypeScript } from '../types';
|
|
5
5
|
export declare class ConfigSet {
|
|
6
|
+
private readonly jestConfig;
|
|
7
|
+
private readonly parentLogger?;
|
|
6
8
|
readonly logger: Logger;
|
|
7
9
|
readonly compilerModule: TTypeScript;
|
|
8
10
|
readonly isolatedModules: boolean;
|
|
@@ -15,7 +17,7 @@ export declare class ConfigSet {
|
|
|
15
17
|
constructor(jestConfig: Config.ProjectConfig, parentLogger?: Logger | undefined);
|
|
16
18
|
protected _resolveTsConfig(compilerOptions?: CompilerOptions, resolvedConfigFile?: string): Record<string, any>;
|
|
17
19
|
get tsJestDigest(): string;
|
|
18
|
-
|
|
20
|
+
isTestFile(fileName: string): boolean;
|
|
19
21
|
shouldStringifyContent(filePath: string): boolean;
|
|
20
22
|
raiseDiagnostics(diagnostics: Diagnostic[], filePath?: string, logger?: Logger): void;
|
|
21
23
|
shouldReportDiagnostics(filePath: string): boolean;
|
|
@@ -117,8 +117,8 @@ var toDiagnosticCodeList = function (items, into) {
|
|
|
117
117
|
};
|
|
118
118
|
var ConfigSet = (function () {
|
|
119
119
|
function ConfigSet(jestConfig, parentLogger) {
|
|
120
|
-
var _a;
|
|
121
|
-
var
|
|
120
|
+
var _a, _b;
|
|
121
|
+
var _c, _d, _e, _f;
|
|
122
122
|
this.jestConfig = jestConfig;
|
|
123
123
|
this.parentLogger = parentLogger;
|
|
124
124
|
this.customTransformers = Object.create(null);
|
|
@@ -141,16 +141,23 @@ var ConfigSet = (function () {
|
|
|
141
141
|
this.logger = this.parentLogger
|
|
142
142
|
? this.parentLogger.child((_a = {}, _a[bs_logger_1.LogContexts.namespace] = 'config', _a))
|
|
143
143
|
: logger_1.rootLogger.child({ namespace: 'config' });
|
|
144
|
-
this.cwd = path_1.normalize((
|
|
145
|
-
this.rootDir = path_1.normalize((
|
|
144
|
+
this.cwd = path_1.normalize((_c = this.jestConfig.cwd) !== null && _c !== void 0 ? _c : process.cwd());
|
|
145
|
+
this.rootDir = path_1.normalize((_d = this.jestConfig.rootDir) !== null && _d !== void 0 ? _d : this.cwd);
|
|
146
146
|
var tsJestCfg = this.jestConfig.globals && this.jestConfig.globals['ts-jest'];
|
|
147
147
|
var options = tsJestCfg !== null && tsJestCfg !== void 0 ? tsJestCfg : Object.create(null);
|
|
148
|
-
this.compilerModule = importer_1.importer.typescript("Using \"ts-jest\" requires this package to be installed.", (
|
|
149
|
-
this.isolatedModules = (
|
|
148
|
+
this.compilerModule = importer_1.importer.typescript("Using \"ts-jest\" requires this package to be installed.", (_e = options.compiler) !== null && _e !== void 0 ? _e : 'typescript');
|
|
149
|
+
this.isolatedModules = (_f = options.isolatedModules) !== null && _f !== void 0 ? _f : false;
|
|
150
150
|
this.logger.debug({ compilerModule: this.compilerModule }, 'normalized compiler module config via ts-jest option');
|
|
151
151
|
this._backportJestCfg();
|
|
152
152
|
this._setupTsJestCfg(options);
|
|
153
153
|
this._resolveTsCacheDir();
|
|
154
|
+
this._matchablePatterns = __spread(this._jestCfg.testMatch, this._jestCfg.testRegex).filter(function (pattern) {
|
|
155
|
+
return pattern instanceof RegExp || typeof pattern === 'string';
|
|
156
|
+
});
|
|
157
|
+
if (!this._matchablePatterns.length) {
|
|
158
|
+
(_b = this._matchablePatterns).push.apply(_b, __spread(constants_1.DEFAULT_JEST_TEST_MATCH));
|
|
159
|
+
}
|
|
160
|
+
this._matchTestFilePath = jest_util_1.globsToMatcher(this._matchablePatterns.filter(function (pattern) { return typeof pattern === 'string'; }));
|
|
154
161
|
}
|
|
155
162
|
ConfigSet.prototype._backportJestCfg = function () {
|
|
156
163
|
var config = backports_1.backportJestConfig(this.logger, this.jestConfig);
|
|
@@ -159,7 +166,7 @@ var ConfigSet = (function () {
|
|
|
159
166
|
};
|
|
160
167
|
ConfigSet.prototype._setupTsJestCfg = function (options) {
|
|
161
168
|
var _this = this;
|
|
162
|
-
var _a, _b, _c;
|
|
169
|
+
var _a, _b, _c, _d;
|
|
163
170
|
if (options.packageJson) {
|
|
164
171
|
this.logger.warn("The option `packageJson` is deprecated and will be removed in ts-jest 27. This option is not used by internal `ts-jest`");
|
|
165
172
|
}
|
|
@@ -203,23 +210,36 @@ var ConfigSet = (function () {
|
|
|
203
210
|
}
|
|
204
211
|
this._diagnostics = {
|
|
205
212
|
pretty: (_b = diagnosticsOpt.pretty) !== null && _b !== void 0 ? _b : true,
|
|
213
|
+
exclude: (_c = diagnosticsOpt.exclude) !== null && _c !== void 0 ? _c : [],
|
|
206
214
|
ignoreCodes: toDiagnosticCodeList(ignoreList),
|
|
207
|
-
pathRegex: normalizeRegex(diagnosticsOpt.pathRegex),
|
|
208
215
|
throws: !diagnosticsOpt.warnOnly,
|
|
209
216
|
};
|
|
217
|
+
if (diagnosticsOpt.pathRegex) {
|
|
218
|
+
this.logger.warn("The option `pathRegex` is deprecated and will be removed in ts-jest 27, use `exclude` instead");
|
|
219
|
+
this._diagnostics = __assign(__assign({}, this._diagnostics), { pathRegex: normalizeRegex(diagnosticsOpt.pathRegex) });
|
|
220
|
+
}
|
|
210
221
|
}
|
|
211
222
|
else {
|
|
212
223
|
this._diagnostics = {
|
|
213
224
|
ignoreCodes: diagnosticsOpt ? toDiagnosticCodeList(ignoreList) : [],
|
|
225
|
+
exclude: [],
|
|
214
226
|
pretty: true,
|
|
215
227
|
throws: diagnosticsOpt,
|
|
216
228
|
};
|
|
217
229
|
}
|
|
230
|
+
if (this._diagnostics.pathRegex && !this._diagnostics.exclude.length) {
|
|
231
|
+
this._shouldGetDiagnosticsForFile = new RegExp(this._diagnostics.pathRegex);
|
|
232
|
+
}
|
|
233
|
+
else {
|
|
234
|
+
this._shouldGetDiagnosticsForFile = this._diagnostics.exclude.length
|
|
235
|
+
? jest_util_1.globsToMatcher(this._diagnostics.exclude)
|
|
236
|
+
: function () { return true; };
|
|
237
|
+
}
|
|
218
238
|
this.logger.debug({ diagnostics: this._diagnostics }, 'normalized diagnostics config via ts-jest option');
|
|
219
239
|
if (options.tsConfig) {
|
|
220
240
|
this.logger.warn("The option `tsConfig` is deprecated and will be removed in ts-jest 27, use `tsconfig` instead");
|
|
221
241
|
}
|
|
222
|
-
var tsconfigOpt = (
|
|
242
|
+
var tsconfigOpt = (_d = options.tsConfig) !== null && _d !== void 0 ? _d : options.tsconfig;
|
|
223
243
|
var configFilePath = typeof tsconfigOpt === 'string' ? this.resolvePath(tsconfigOpt) : undefined;
|
|
224
244
|
this.parsedTsConfig = this._resolveTsConfig(typeof tsconfigOpt === 'object' ? tsconfigOpt : undefined, configFilePath);
|
|
225
245
|
this.raiseDiagnostics(this.parsedTsConfig.errors, configFilePath);
|
|
@@ -411,23 +431,12 @@ var ConfigSet = (function () {
|
|
|
411
431
|
enumerable: false,
|
|
412
432
|
configurable: true
|
|
413
433
|
});
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
matchablePatterns.push.apply(matchablePatterns, __spread(constants_1.DEFAULT_JEST_TEST_MATCH));
|
|
421
|
-
}
|
|
422
|
-
var stringPatterns = matchablePatterns.filter(function (pattern) { return typeof pattern === 'string'; });
|
|
423
|
-
var isMatch = jest_util_1.globsToMatcher(stringPatterns);
|
|
424
|
-
return function (fileName) {
|
|
425
|
-
return matchablePatterns.some(function (pattern) { return (typeof pattern === 'string' ? isMatch(fileName) : pattern.test(fileName)); });
|
|
426
|
-
};
|
|
427
|
-
},
|
|
428
|
-
enumerable: false,
|
|
429
|
-
configurable: true
|
|
430
|
-
});
|
|
434
|
+
ConfigSet.prototype.isTestFile = function (fileName) {
|
|
435
|
+
var _this = this;
|
|
436
|
+
return this._matchablePatterns.some(function (pattern) {
|
|
437
|
+
return typeof pattern === 'string' ? _this._matchTestFilePath(fileName) : pattern.test(fileName);
|
|
438
|
+
});
|
|
439
|
+
};
|
|
431
440
|
ConfigSet.prototype.shouldStringifyContent = function (filePath) {
|
|
432
441
|
return this._stringifyContentRegExp ? this._stringifyContentRegExp.test(filePath) : false;
|
|
433
442
|
};
|
|
@@ -454,14 +463,9 @@ var ConfigSet = (function () {
|
|
|
454
463
|
logger ? logger.warn({ error: error }, error.message) : this.logger.warn({ error: error }, error.message);
|
|
455
464
|
};
|
|
456
465
|
ConfigSet.prototype.shouldReportDiagnostics = function (filePath) {
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
return regex.test(filePath);
|
|
461
|
-
}
|
|
462
|
-
else {
|
|
463
|
-
return true;
|
|
464
|
-
}
|
|
466
|
+
return this._shouldGetDiagnosticsForFile instanceof RegExp
|
|
467
|
+
? this._shouldGetDiagnosticsForFile.test(filePath)
|
|
468
|
+
: this._shouldGetDiagnosticsForFile(filePath);
|
|
465
469
|
};
|
|
466
470
|
ConfigSet.prototype._createTsError = function (diagnostics) {
|
|
467
471
|
var _this = this;
|
|
@@ -518,9 +522,6 @@ var ConfigSet = (function () {
|
|
|
518
522
|
__decorate([
|
|
519
523
|
memoize_1.Memoize()
|
|
520
524
|
], ConfigSet.prototype, "hooks", null);
|
|
521
|
-
__decorate([
|
|
522
|
-
memoize_1.Memoize()
|
|
523
|
-
], ConfigSet.prototype, "isTestFile", null);
|
|
524
525
|
return ConfigSet;
|
|
525
526
|
}());
|
|
526
527
|
exports.ConfigSet = ConfigSet;
|
package/dist/types.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Config } from '@jest/types';
|
|
1
2
|
import type * as _babel from 'babel__core';
|
|
2
3
|
import type * as _ts from 'typescript';
|
|
3
4
|
export declare type TTypeScript = typeof _ts;
|
|
@@ -22,6 +23,7 @@ export interface TsJestGlobalOptions {
|
|
|
22
23
|
pretty?: boolean;
|
|
23
24
|
ignoreCodes?: number | string | (number | string)[];
|
|
24
25
|
pathRegex?: RegExp | string;
|
|
26
|
+
exclude?: Config.Glob[];
|
|
25
27
|
warnOnly?: boolean;
|
|
26
28
|
};
|
|
27
29
|
babelConfig?: boolean | string | BabelConfig;
|
|
@@ -31,6 +33,7 @@ export interface TsJestDiagnosticsCfg {
|
|
|
31
33
|
pretty: boolean;
|
|
32
34
|
ignoreCodes: number[];
|
|
33
35
|
pathRegex?: string | undefined;
|
|
36
|
+
exclude: Config.Glob[];
|
|
34
37
|
throws: boolean;
|
|
35
38
|
warnOnly?: boolean;
|
|
36
39
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ts-jest",
|
|
3
|
-
"version": "26.
|
|
3
|
+
"version": "26.5.0",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"bin": {
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"fast-json-stable-stringify": "2.x",
|
|
64
64
|
"jest-util": "^26.1.0",
|
|
65
65
|
"json5": "2.x",
|
|
66
|
-
"lodash
|
|
66
|
+
"lodash": "4.x",
|
|
67
67
|
"make-error": "1.x",
|
|
68
68
|
"mkdirp": "1.x",
|
|
69
69
|
"semver": "7.x",
|
|
@@ -91,9 +91,7 @@
|
|
|
91
91
|
"@types/fs-extra": "latest",
|
|
92
92
|
"@types/js-yaml": "latest",
|
|
93
93
|
"@types/json5": "latest",
|
|
94
|
-
"@types/lodash
|
|
95
|
-
"@types/lodash.merge": "4.x",
|
|
96
|
-
"@types/lodash.set": "4.x",
|
|
94
|
+
"@types/lodash": "4.x",
|
|
97
95
|
"@types/micromatch": "4.x",
|
|
98
96
|
"@types/mkdirp": "latest",
|
|
99
97
|
"@types/node": "14.x",
|
|
@@ -117,8 +115,6 @@
|
|
|
117
115
|
"jest": "26.x",
|
|
118
116
|
"js-yaml": "latest",
|
|
119
117
|
"lint-staged": "latest",
|
|
120
|
-
"lodash.merge": "4.x",
|
|
121
|
-
"lodash.set": "4.x",
|
|
122
118
|
"npm-run-all": "latest",
|
|
123
119
|
"prettier": "2.x",
|
|
124
120
|
"source-map": "latest",
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export default [
|
|
2
|
+
require("/Users/ahn/ts-jest/website/node_modules/remark-admonitions/styles/infima.css"),
|
|
3
|
+
require("/Users/ahn/ts-jest/website/node_modules/remark-admonitions/styles/infima.css"),
|
|
4
|
+
require("/Users/ahn/ts-jest/website/node_modules/remark-admonitions/styles/infima.css"),
|
|
5
|
+
require("/Users/ahn/ts-jest/website/node_modules/infima/dist/css/default/default.css"),
|
|
6
|
+
require("/Users/ahn/ts-jest/website/node_modules/@docusaurus/theme-classic/lib/prism-include-languages"),
|
|
7
|
+
require("/Users/ahn/ts-jest/website/src/css/custom.css"),
|
|
8
|
+
];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "babel7-or-ts",
|
|
3
|
+
"id": "babel7-or-ts",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Babel7 or TypeScript",
|
|
6
|
+
"description": "In Sept. 2018 Babel7 got released with an interesting preset: @babel/preset-typescript.",
|
|
7
|
+
"source": "@site/docs/babel7-or-ts.md",
|
|
8
|
+
"slug": "/babel7-or-ts",
|
|
9
|
+
"permalink": "/ts-jest/docs/babel7-or-ts",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/babel7-or-ts.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Troubleshooting",
|
|
15
|
+
"permalink": "/ts-jest/docs/troubleshooting"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Migration from <=23.10",
|
|
19
|
+
"permalink": "/ts-jest/docs/migration"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "contributing",
|
|
3
|
+
"id": "contributing",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Contributing",
|
|
6
|
+
"description": "Check our contributing guide",
|
|
7
|
+
"source": "@site/docs/contributing.md",
|
|
8
|
+
"slug": "/contributing",
|
|
9
|
+
"permalink": "/ts-jest/docs/contributing",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/contributing.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Migration from <=23.10",
|
|
15
|
+
"permalink": "/ts-jest/docs/migration"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Jest flow",
|
|
19
|
+
"permalink": "/ts-jest/docs/processing"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "contribution",
|
|
3
|
+
"id": "contribution",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "contribution",
|
|
6
|
+
"description": "",
|
|
7
|
+
"source": "@site/docs/contribution.md",
|
|
8
|
+
"slug": "/contribution",
|
|
9
|
+
"permalink": "/ts-jest/docs/contribution",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/contribution.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-debugging-md-2bc.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "debugging",
|
|
3
|
+
"id": "debugging",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Debugging ts-jest",
|
|
6
|
+
"description": "You can activate the debug logger by setting the environment variable TSJESTLOG before running tests.",
|
|
7
|
+
"source": "@site/docs/debugging.md",
|
|
8
|
+
"slug": "/debugging",
|
|
9
|
+
"permalink": "/ts-jest/docs/debugging",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/debugging.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Migration from <=23.10",
|
|
15
|
+
"permalink": "/ts-jest/docs/migration"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Jest flow",
|
|
19
|
+
"permalink": "/ts-jest/docs/processing"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "e2e-testing",
|
|
3
|
+
"id": "e2e-testing",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "E2E tests flow",
|
|
6
|
+
"description": "These are internal technical documents. If you're not a contributor to ts-jest, but simply trying to use the library you'll find nothing of value here",
|
|
7
|
+
"source": "@site/docs/e2e-testing.md",
|
|
8
|
+
"slug": "/e2e-testing",
|
|
9
|
+
"permalink": "/ts-jest/docs/e2e-testing",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/e2e-testing.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Jest flow",
|
|
15
|
+
"permalink": "/ts-jest/docs/processing"
|
|
16
|
+
}
|
|
17
|
+
}
|
package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-esm-support-md-ff2.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "esm-support",
|
|
3
|
+
"id": "esm-support",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "ESM Support",
|
|
6
|
+
"description": "To use ts-jest with ESM support, you'll first need to check ESM Jest documentation.",
|
|
7
|
+
"source": "@site/docs/esm-support.md",
|
|
8
|
+
"slug": "/esm-support",
|
|
9
|
+
"permalink": "/ts-jest/docs/esm-support",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/esm-support.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Test helpers",
|
|
15
|
+
"permalink": "/ts-jest/docs/test-helpers"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Using with React Native",
|
|
19
|
+
"permalink": "/ts-jest/docs/react-native"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "installation",
|
|
3
|
+
"id": "installation",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Installation",
|
|
6
|
+
"description": "ts-jest is a Typescript preprocessor for Jest pre-processor. You'll need both Jest and TypeScript installed inside your project.",
|
|
7
|
+
"source": "@site/docs/installation.md",
|
|
8
|
+
"slug": "/installation",
|
|
9
|
+
"permalink": "/ts-jest/docs/installation",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/installation.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"next": {
|
|
14
|
+
"title": "Presets",
|
|
15
|
+
"permalink": "/ts-jest/docs/presets"
|
|
16
|
+
}
|
|
17
|
+
}
|
package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-migration-md-295.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "migration",
|
|
3
|
+
"id": "migration",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Migration from <=23.10",
|
|
6
|
+
"description": "You can use the config:migrate tool of ts-jest CLI if you're coming from an older version to help you migrate your Jest configuration.",
|
|
7
|
+
"source": "@site/docs/migration.md",
|
|
8
|
+
"slug": "/migration",
|
|
9
|
+
"permalink": "/ts-jest/docs/migration",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/migration.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Babel7 or TypeScript",
|
|
15
|
+
"permalink": "/ts-jest/docs/babel7-or-ts"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Debugging ts-jest",
|
|
19
|
+
"permalink": "/ts-jest/docs/debugging"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/astTransformers",
|
|
3
|
+
"id": "options/astTransformers",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "AST transformers option",
|
|
6
|
+
"description": "ts-jest by default does hoisting for a few jest methods via a TypeScript AST transformer. One can also create custom",
|
|
7
|
+
"source": "@site/docs/options/astTransformers.md",
|
|
8
|
+
"slug": "/options/astTransformers",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/astTransformers",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/astTransformers.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/babelConfig",
|
|
3
|
+
"id": "options/babelConfig",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Babel Config option",
|
|
6
|
+
"description": "ts-jest by default does NOT use Babel. But you may want to use it, especially if your code rely on Babel plugins to make some transformations. ts-jest can call the BabelJest processor once TypeScript has transformed the source into JavaScript.",
|
|
7
|
+
"source": "@site/docs/options/babelConfig.md",
|
|
8
|
+
"slug": "/options/babelConfig",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/babelConfig",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/babelConfig.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/compiler",
|
|
3
|
+
"id": "options/compiler",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Compiler option",
|
|
6
|
+
"description": "The compiler option allows you to define the compiler to be used. It'll be used to load the NodeJS module holding the TypeScript compiler.",
|
|
7
|
+
"source": "@site/docs/options/compiler.md",
|
|
8
|
+
"slug": "/options/compiler",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/compiler",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/compiler.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/diagnostics",
|
|
3
|
+
"id": "options/diagnostics",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Diagnostics option",
|
|
6
|
+
"description": "The diagnostics option configures error reporting.",
|
|
7
|
+
"source": "@site/docs/options/diagnostics.md",
|
|
8
|
+
"slug": "/options/diagnostics",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/diagnostics",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/diagnostics.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/isolatedModules",
|
|
3
|
+
"id": "options/isolatedModules",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Isolated Modules option",
|
|
6
|
+
"description": "By default ts-jest uses TypeScript compiler in the context of a project (yours), with full type-checking and features.",
|
|
7
|
+
"source": "@site/docs/options/isolatedModules.md",
|
|
8
|
+
"slug": "/options/isolatedModules",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/isolatedModules",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/isolatedModules.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-options-md-aeb.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options",
|
|
3
|
+
"id": "options",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Options",
|
|
6
|
+
"description": "Introduction",
|
|
7
|
+
"source": "@site/docs/options.md",
|
|
8
|
+
"slug": "/options",
|
|
9
|
+
"permalink": "/ts-jest/docs/options",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Paths mapping",
|
|
15
|
+
"permalink": "/ts-jest/docs/paths-mapping"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Version checking",
|
|
19
|
+
"permalink": "/ts-jest/docs/version-checking"
|
|
20
|
+
}
|
|
21
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/stringifyContentPathRegex",
|
|
3
|
+
"id": "options/stringifyContentPathRegex",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Stringify content option",
|
|
6
|
+
"description": "The stringifyContentPathRegex option has been kept for backward compatibility of HTML_TRANSFORM",
|
|
7
|
+
"source": "@site/docs/options/stringifyContentPathRegex.md",
|
|
8
|
+
"slug": "/options/stringifyContentPathRegex",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/stringifyContentPathRegex",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/stringifyContentPathRegex.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/tsconfig",
|
|
3
|
+
"id": "options/tsconfig",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "TypeScript Config option",
|
|
6
|
+
"description": "The tsconfig option allows you to define which tsconfig JSON file to use. An inline compiler options object can also be specified instead of a file path.",
|
|
7
|
+
"source": "@site/docs/options/tsconfig.md",
|
|
8
|
+
"slug": "/options/tsconfig",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/tsconfig",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/tsconfig.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "options/useESM",
|
|
3
|
+
"id": "options/useESM",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "useESM option",
|
|
6
|
+
"description": "The useESM option allows ts-jest to transform codes to ESM syntax if possible.",
|
|
7
|
+
"source": "@site/docs/options/useESM.md",
|
|
8
|
+
"slug": "/options/useESM",
|
|
9
|
+
"permalink": "/ts-jest/docs/options/useESM",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/options/useESM.md",
|
|
11
|
+
"version": "current"
|
|
12
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "paths-mapping",
|
|
3
|
+
"id": "paths-mapping",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Paths mapping",
|
|
6
|
+
"description": "If you use \"baseUrl\" and \"paths\" options in your tsconfig file, you should make sure the \"moduleNameMapper\" option in your Jest config is setup accordingly.",
|
|
7
|
+
"source": "@site/docs/paths-mapping.md",
|
|
8
|
+
"slug": "/paths-mapping",
|
|
9
|
+
"permalink": "/ts-jest/docs/paths-mapping",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/paths-mapping.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Presets",
|
|
15
|
+
"permalink": "/ts-jest/docs/presets"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Options",
|
|
19
|
+
"permalink": "/ts-jest/docs/options"
|
|
20
|
+
}
|
|
21
|
+
}
|
package/website/.docusaurus/docusaurus-plugin-content-docs/default/site-docs-presets-md-02b.json
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"unversionedId": "presets",
|
|
3
|
+
"id": "presets",
|
|
4
|
+
"isDocsHomePage": false,
|
|
5
|
+
"title": "Presets",
|
|
6
|
+
"description": "The presets",
|
|
7
|
+
"source": "@site/docs/presets.md",
|
|
8
|
+
"slug": "/presets",
|
|
9
|
+
"permalink": "/ts-jest/docs/presets",
|
|
10
|
+
"editUrl": "https://github.com/kulshekhar/ts-jest/edit/master/docs/docs/presets.md",
|
|
11
|
+
"version": "current",
|
|
12
|
+
"sidebar": "docs",
|
|
13
|
+
"previous": {
|
|
14
|
+
"title": "Installation",
|
|
15
|
+
"permalink": "/ts-jest/docs/installation"
|
|
16
|
+
},
|
|
17
|
+
"next": {
|
|
18
|
+
"title": "Paths mapping",
|
|
19
|
+
"permalink": "/ts-jest/docs/paths-mapping"
|
|
20
|
+
}
|
|
21
|
+
}
|