@forsakringskassan/vitest-config 2.5.0 → 2.6.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/dist/index.js +21 -6
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -139,11 +139,12 @@ import { fileURLToPath } from "node:url";
|
|
|
139
139
|
var e = globalThis.process?.env || /* @__PURE__ */ Object.create(null);
|
|
140
140
|
var t = globalThis.process || { env: e };
|
|
141
141
|
var n = t !== void 0 && t.env && t.env.NODE_ENV || void 0;
|
|
142
|
-
var r = [[`claude`, [`CLAUDECODE`, `CLAUDE_CODE`]], [`replit`, [`REPL_ID`]], [`gemini`, [`GEMINI_CLI`]], [`codex`, [`CODEX_SANDBOX`, `CODEX_THREAD_ID`]], [`opencode`, [`OPENCODE`]], [`pi`, [i(`PATH`, /\.pi[\\/]agent/)]], [`auggie`, [`AUGMENT_AGENT`]], [`goose`, [`GOOSE_PROVIDER`]], [`devin`, [i(`EDITOR`, /devin/)]], [`cursor`, [`CURSOR_AGENT`]], [`kiro`, [i(`TERM_PROGRAM`, /kiro
|
|
143
|
-
function i(
|
|
142
|
+
var r = [[`claude`, [`CLAUDECODE`, `CLAUDE_CODE`]], [`replit`, [`REPL_ID`]], [`gemini`, [`GEMINI_CLI`]], [`codex`, [`CODEX_SANDBOX`, `CODEX_THREAD_ID`]], [`opencode`, [`OPENCODE`]], [`pi`, [i(`PATH`, /\.pi[\\/]agent/)]], [`auggie`, [`AUGMENT_AGENT`]], [`goose`, [`GOOSE_PROVIDER`]], [`junie`, [`JUNIE_DATA`, `JUNIE_SHIM_PATH`]], [`devin`, [i(`EDITOR`, /devin/)]], [`cursor`, [`CURSOR_AGENT`]], [`kiro`, [i(`TERM_PROGRAM`, /kiro/, { noTTY: true })]]];
|
|
143
|
+
function i(n2, r2, i2) {
|
|
144
144
|
return () => {
|
|
145
|
-
|
|
146
|
-
|
|
145
|
+
if (i2?.noTTY && t.stdout?.isTTY) return false;
|
|
146
|
+
let a2 = e[n2];
|
|
147
|
+
return a2 ? r2.test(a2) : false;
|
|
147
148
|
};
|
|
148
149
|
}
|
|
149
150
|
function a() {
|
|
@@ -380,14 +381,28 @@ function defineTestConfig(userConfig = {}) {
|
|
|
380
381
|
provider: mod,
|
|
381
382
|
reporter: ["text", "text-summary", "lcov"],
|
|
382
383
|
include: ["src/**/*.[jt]s"],
|
|
383
|
-
exclude: [
|
|
384
|
+
exclude: [
|
|
385
|
+
"**/*.cy.ts",
|
|
386
|
+
"**/*.d.ts",
|
|
387
|
+
"**/__fixtures__/**",
|
|
388
|
+
"**/generated/**",
|
|
389
|
+
"**/index.[jt]s",
|
|
390
|
+
"**/temp/**"
|
|
391
|
+
]
|
|
384
392
|
},
|
|
385
393
|
reporters: [
|
|
386
394
|
"default",
|
|
387
395
|
["junit", { suiteName: "Vitest tests" }],
|
|
388
396
|
...githubReporter
|
|
389
397
|
],
|
|
390
|
-
outputFile: "./test-results/vitest-junit.xml"
|
|
398
|
+
outputFile: "./test-results/vitest-junit.xml",
|
|
399
|
+
exclude: [
|
|
400
|
+
"**/.git/**",
|
|
401
|
+
"**/build/**",
|
|
402
|
+
"**/dist/**",
|
|
403
|
+
"**/node_modules/**",
|
|
404
|
+
"**/temp/**"
|
|
405
|
+
]
|
|
391
406
|
};
|
|
392
407
|
const resolvedConfig = userConfig ? (0, import_deepmerge.default)(defaultConfig, userConfig, { arrayMerge: overwriteMerge }) : defaultConfig;
|
|
393
408
|
return resolvedConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forsakringskassan/vitest-config",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.6.0",
|
|
4
4
|
"description": "Försäkringskassan shareable config for Vitest",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"vitest"
|
|
@@ -37,5 +37,5 @@
|
|
|
37
37
|
"node": ">= 22.12.0",
|
|
38
38
|
"npm": ">= 10.0.0"
|
|
39
39
|
},
|
|
40
|
-
"gitHead": "
|
|
40
|
+
"gitHead": "efa58b53f5c690ed25dd5cd15af8ea7903968520"
|
|
41
41
|
}
|