@nx/jest 22.2.1 → 22.3.0-canary.20251211-205daee
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/package.json +4 -4
- package/src/plugins/plugin.js +33 -23
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nx/jest",
|
|
3
|
-
"version": "22.
|
|
3
|
+
"version": "22.3.0-canary.20251211-205daee",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "The Nx Plugin for Jest contains executors and generators allowing your workspace to use the powerful Jest testing capabilities.",
|
|
6
6
|
"repository": {
|
|
@@ -37,8 +37,8 @@
|
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"@jest/reporters": "^30.0.2",
|
|
39
39
|
"@jest/test-result": "^30.0.2",
|
|
40
|
-
"@nx/devkit": "22.
|
|
41
|
-
"@nx/js": "22.
|
|
40
|
+
"@nx/devkit": "22.3.0-canary.20251211-205daee",
|
|
41
|
+
"@nx/js": "22.3.0-canary.20251211-205daee",
|
|
42
42
|
"@phenomnomnominal/tsquery": "~5.0.1",
|
|
43
43
|
"identity-obj-proxy": "3.0.0",
|
|
44
44
|
"jest-config": "^30.0.2",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"yargs-parser": "21.1.1"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"nx": "22.
|
|
55
|
+
"nx": "22.3.0-canary.20251211-205daee"
|
|
56
56
|
},
|
|
57
57
|
"publishConfig": {
|
|
58
58
|
"access": "public"
|
package/src/plugins/plugin.js
CHANGED
|
@@ -181,7 +181,12 @@ async function buildJestTargets(configFilePath, projectRoot, options, context, p
|
|
|
181
181
|
continue;
|
|
182
182
|
}
|
|
183
183
|
const targetName = `${options.ciTargetName}--${relativePath}`;
|
|
184
|
-
dependsOn.push(
|
|
184
|
+
dependsOn.push({
|
|
185
|
+
target: targetName,
|
|
186
|
+
projects: 'self',
|
|
187
|
+
params: 'forward',
|
|
188
|
+
options: 'forward',
|
|
189
|
+
});
|
|
185
190
|
targets[targetName] = {
|
|
186
191
|
command: `jest ${relativePath}`,
|
|
187
192
|
cache,
|
|
@@ -268,27 +273,6 @@ async function buildJestTargets(configFilePath, projectRoot, options, context, p
|
|
|
268
273
|
},
|
|
269
274
|
};
|
|
270
275
|
const dependsOn = [];
|
|
271
|
-
targets[options.ciTargetName] = {
|
|
272
|
-
executor: 'nx:noop',
|
|
273
|
-
cache: true,
|
|
274
|
-
inputs,
|
|
275
|
-
outputs,
|
|
276
|
-
dependsOn,
|
|
277
|
-
metadata: {
|
|
278
|
-
technologies: ['jest'],
|
|
279
|
-
description: 'Run Jest Tests in CI',
|
|
280
|
-
nonAtomizedTarget: options.targetName,
|
|
281
|
-
help: {
|
|
282
|
-
command: `${pmc.exec} jest --help`,
|
|
283
|
-
example: {
|
|
284
|
-
options: {
|
|
285
|
-
coverage: true,
|
|
286
|
-
},
|
|
287
|
-
},
|
|
288
|
-
},
|
|
289
|
-
},
|
|
290
|
-
};
|
|
291
|
-
targetGroup.push(options.ciTargetName);
|
|
292
276
|
for (const testPath of testPaths) {
|
|
293
277
|
const relativePath = (0, devkit_1.normalizePath)((0, node_path_1.relative)((0, node_path_1.join)(context.workspaceRoot, projectRoot), testPath));
|
|
294
278
|
if (relativePath.includes('../')) {
|
|
@@ -301,7 +285,12 @@ async function buildJestTargets(configFilePath, projectRoot, options, context, p
|
|
|
301
285
|
}, null, 2)}`);
|
|
302
286
|
}
|
|
303
287
|
const targetName = `${options.ciTargetName}--${relativePath}`;
|
|
304
|
-
dependsOn.push(
|
|
288
|
+
dependsOn.push({
|
|
289
|
+
target: targetName,
|
|
290
|
+
projects: 'self',
|
|
291
|
+
params: 'forward',
|
|
292
|
+
options: 'forward',
|
|
293
|
+
});
|
|
305
294
|
targets[targetName] = {
|
|
306
295
|
command: `jest ${relativePath}`,
|
|
307
296
|
cache,
|
|
@@ -326,6 +315,27 @@ async function buildJestTargets(configFilePath, projectRoot, options, context, p
|
|
|
326
315
|
};
|
|
327
316
|
targetGroup.push(targetName);
|
|
328
317
|
}
|
|
318
|
+
targets[options.ciTargetName] = {
|
|
319
|
+
executor: 'nx:noop',
|
|
320
|
+
cache: true,
|
|
321
|
+
inputs,
|
|
322
|
+
outputs,
|
|
323
|
+
dependsOn,
|
|
324
|
+
metadata: {
|
|
325
|
+
technologies: ['jest'],
|
|
326
|
+
description: 'Run Jest Tests in CI',
|
|
327
|
+
nonAtomizedTarget: options.targetName,
|
|
328
|
+
help: {
|
|
329
|
+
command: `${pmc.exec} jest --help`,
|
|
330
|
+
example: {
|
|
331
|
+
options: {
|
|
332
|
+
coverage: true,
|
|
333
|
+
},
|
|
334
|
+
},
|
|
335
|
+
},
|
|
336
|
+
},
|
|
337
|
+
};
|
|
338
|
+
targetGroup.unshift(options.ciTargetName);
|
|
329
339
|
}
|
|
330
340
|
}
|
|
331
341
|
}
|