@layerzerolabs/vitest-configuration 1.2.25 → 1.2.28
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.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +22 -9
- package/dist/index.js.map +1 -1
- package/package.json +3 -3
- package/src/index.ts +29 -7
- package/.turbo/turbo-build.log +0 -15
- package/.turbo/turbo-lint.log +0 -8
- package/.turbo/turbo-test.log +0 -18
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AASpD,eAAO,MAAM,YAAY,GAAI,sBAAqB,cAAmB,KAAG,cA8BnE,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -2,19 +2,32 @@ import { mergeConfig, defineConfig as defineConfig$1 } from 'vitest/config';
|
|
|
2
2
|
|
|
3
3
|
var __defProp = Object.defineProperty;
|
|
4
4
|
var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
|
|
5
|
-
var
|
|
5
|
+
var typecheck = {
|
|
6
|
+
enabled: true,
|
|
7
|
+
include: [
|
|
8
|
+
"**/*.test.ts{,x}"
|
|
9
|
+
],
|
|
10
|
+
tsconfig: "tsconfig.test.json"
|
|
11
|
+
};
|
|
12
|
+
var defineConfig = /* @__PURE__ */ __name(({ test, ...config } = {}) => mergeConfig(defineConfig$1({
|
|
6
13
|
test: {
|
|
7
14
|
passWithNoTests: true,
|
|
8
|
-
typecheck
|
|
9
|
-
enabled: true,
|
|
10
|
-
include: [
|
|
11
|
-
"**/*.test.ts{,x}"
|
|
12
|
-
],
|
|
13
|
-
tsconfig: "tsconfig.test.json"
|
|
14
|
-
},
|
|
15
|
+
typecheck,
|
|
15
16
|
watch: false
|
|
16
17
|
}
|
|
17
|
-
}), defineConfig$1(
|
|
18
|
+
}), defineConfig$1({
|
|
19
|
+
...config,
|
|
20
|
+
test: {
|
|
21
|
+
...test,
|
|
22
|
+
projects: test?.projects ? test.projects.map((project) => typeof project === "string" || typeof project === "function" || project instanceof Promise ? project : {
|
|
23
|
+
...project,
|
|
24
|
+
test: {
|
|
25
|
+
...project.test,
|
|
26
|
+
typecheck
|
|
27
|
+
}
|
|
28
|
+
}) : void 0
|
|
29
|
+
}
|
|
30
|
+
})), "defineConfig");
|
|
18
31
|
|
|
19
32
|
export { defineConfig };
|
|
20
33
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"names":["defineConfig","config","mergeConfig","defineVitestConfig","
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":["typecheck","enabled","include","tsconfig","defineConfig","test","config","mergeConfig","defineVitestConfig","passWithNoTests","watch","projects","map","project","Promise","undefined"],"mappings":";;;;AAGA,IAAMA,SAAAA,GAAY;EACdC,OAAAA,EAAS,IAAA;EACTC,OAAAA,EAAS;AAAC,IAAA;;EACVC,QAAAA,EAAU;AACd,CAAA;AAEO,IAAMC,YAAAA,mBAAe,MAAA,CAAA,CAAC,EAAEC,IAAAA,EAAM,GAAGC,QAAAA,GAA2B,EAAC,KAChEC,WAAAA,CACIC,cAAAA,CAAmB;EACfH,IAAAA,EAAM;IACFI,eAAAA,EAAiB,IAAA;AACjBT,IAAAA,SAAAA;IACAU,KAAAA,EAAO;AACX;AACJ,CAAA,GACAF,cAAAA,CAAmB;EACf,GAAGF,MAAAA;EACHD,IAAAA,EAAM;IACF,GAAGA,IAAAA;AACHM,IAAAA,QAAAA,EAAUN,IAAAA,EAAMM,QAAAA,GACVN,IAAAA,CAAKM,QAAAA,CAASC,IAAI,CAACC,OAAAA,KACf,OAAOA,OAAAA,KAAY,YACnB,OAAOA,OAAAA,KAAY,UAAA,IACnBA,OAAAA,YAAmBC,UACbD,OAAAA,GACA;MACI,GAAGA,OAAAA;MACHR,IAAAA,EAAM;AACF,QAAA,GAAGQ,OAAAA,CAAQR,IAAAA;AACXL,QAAAA;AACJ;AACJ,KAAA,CAAA,GAEVe;AACV;AACJ,CAAA,CAAA,CAAA,EA7BoB,cAAA","file":"index.js","sourcesContent":["import type { ViteUserConfig } from 'vitest/config';\nimport { defineConfig as defineVitestConfig, mergeConfig } from 'vitest/config';\n\nconst typecheck = {\n enabled: true,\n include: ['**/*.test.ts{,x}'],\n tsconfig: 'tsconfig.test.json',\n};\n\nexport const defineConfig = ({ test, ...config }: ViteUserConfig = {}): ViteUserConfig =>\n mergeConfig(\n defineVitestConfig({\n test: {\n passWithNoTests: true,\n typecheck,\n watch: false,\n },\n }),\n defineVitestConfig({\n ...config,\n test: {\n ...test,\n projects: test?.projects\n ? test.projects.map((project) =>\n typeof project === 'string' ||\n typeof project === 'function' ||\n project instanceof Promise\n ? project\n : {\n ...project,\n test: {\n ...project.test,\n typecheck,\n },\n },\n )\n : undefined,\n },\n }),\n );\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@layerzerolabs/vitest-configuration",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.28",
|
|
4
4
|
"private": false,
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -16,8 +16,8 @@
|
|
|
16
16
|
"tsup": "^8.4.0",
|
|
17
17
|
"typescript": "^6.0.3",
|
|
18
18
|
"vitest": "^3.2.6",
|
|
19
|
-
"@layerzerolabs/tsup-configuration": "1.2.
|
|
20
|
-
"@layerzerolabs/typescript-configuration": "1.2.
|
|
19
|
+
"@layerzerolabs/tsup-configuration": "1.2.28",
|
|
20
|
+
"@layerzerolabs/typescript-configuration": "1.2.28"
|
|
21
21
|
},
|
|
22
22
|
"peerDependencies": {
|
|
23
23
|
"vitest": "^3.2.6"
|
package/src/index.ts
CHANGED
|
@@ -1,18 +1,40 @@
|
|
|
1
1
|
import type { ViteUserConfig } from 'vitest/config';
|
|
2
2
|
import { defineConfig as defineVitestConfig, mergeConfig } from 'vitest/config';
|
|
3
3
|
|
|
4
|
-
|
|
4
|
+
const typecheck = {
|
|
5
|
+
enabled: true,
|
|
6
|
+
include: ['**/*.test.ts{,x}'],
|
|
7
|
+
tsconfig: 'tsconfig.test.json',
|
|
8
|
+
};
|
|
9
|
+
|
|
10
|
+
export const defineConfig = ({ test, ...config }: ViteUserConfig = {}): ViteUserConfig =>
|
|
5
11
|
mergeConfig(
|
|
6
12
|
defineVitestConfig({
|
|
7
13
|
test: {
|
|
8
14
|
passWithNoTests: true,
|
|
9
|
-
typecheck
|
|
10
|
-
enabled: true,
|
|
11
|
-
include: ['**/*.test.ts{,x}'],
|
|
12
|
-
tsconfig: 'tsconfig.test.json',
|
|
13
|
-
},
|
|
15
|
+
typecheck,
|
|
14
16
|
watch: false,
|
|
15
17
|
},
|
|
16
18
|
}),
|
|
17
|
-
defineVitestConfig(
|
|
19
|
+
defineVitestConfig({
|
|
20
|
+
...config,
|
|
21
|
+
test: {
|
|
22
|
+
...test,
|
|
23
|
+
projects: test?.projects
|
|
24
|
+
? test.projects.map((project) =>
|
|
25
|
+
typeof project === 'string' ||
|
|
26
|
+
typeof project === 'function' ||
|
|
27
|
+
project instanceof Promise
|
|
28
|
+
? project
|
|
29
|
+
: {
|
|
30
|
+
...project,
|
|
31
|
+
test: {
|
|
32
|
+
...project.test,
|
|
33
|
+
typecheck,
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
)
|
|
37
|
+
: undefined,
|
|
38
|
+
},
|
|
39
|
+
}),
|
|
18
40
|
);
|
package/.turbo/turbo-build.log
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
WARN Issue while reading "/home/runner/work/monorepo-internal/monorepo-internal/.npmrc". Failed to replace env in config: ${NPM_TOKEN}
|
|
2
|
-
|
|
3
|
-
> @layerzerolabs/vitest-configuration@0.0.0 build /home/runner/work/monorepo-internal/monorepo-internal/tooling-configs/vitest
|
|
4
|
-
> tsup
|
|
5
|
-
|
|
6
|
-
[34mCLI[39m Building entry: src/index.ts
|
|
7
|
-
[34mCLI[39m Using tsconfig: tsconfig.json
|
|
8
|
-
[34mCLI[39m tsup v8.5.1
|
|
9
|
-
[34mCLI[39m Using tsup config: /home/runner/work/monorepo-internal/monorepo-internal/tooling-configs/vitest/tsup.config.ts
|
|
10
|
-
[34mCLI[39m Target: ES2023
|
|
11
|
-
[34mCLI[39m Cleaning output folder
|
|
12
|
-
[34mESM[39m Build start
|
|
13
|
-
[32mESM[39m [1mdist/index.js [22m[32m627.00 B[39m
|
|
14
|
-
[32mESM[39m [1mdist/index.js.map [22m[32m1.13 KB[39m
|
|
15
|
-
[32mESM[39m ⚡️ Build success in 54ms
|
package/.turbo/turbo-lint.log
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
> @layerzerolabs/vitest-configuration@0.0.0 lint /home/runner/work/monorepo-internal/monorepo-internal/tooling-configs/vitest
|
|
3
|
-
> eslint . --max-warnings 0 || (eslint . --fix --max-warnings 0 && false)
|
|
4
|
-
|
|
5
|
-
(node:86722) [MODULE_TYPELESS_PACKAGE_JSON] Warning: Module type of file:///home/runner/work/monorepo-internal/monorepo-internal/eslint.config.js?mtime=1784834384472 is not specified and it doesn't parse as CommonJS.
|
|
6
|
-
Reparsing as ES module because module syntax was detected. This incurs a performance overhead.
|
|
7
|
-
To eliminate this warning, add "type": "module" to /home/runner/work/monorepo-internal/monorepo-internal/package.json.
|
|
8
|
-
(Use `node --trace-warnings ...` to show where the warning was created)
|
package/.turbo/turbo-test.log
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
> @layerzerolabs/vitest-configuration@0.0.0 test /home/runner/work/monorepo-internal/monorepo-internal/tooling-configs/vitest
|
|
3
|
-
> vitest
|
|
4
|
-
|
|
5
|
-
[33mTesting types with tsc and vue-tsc is an experimental feature.
|
|
6
|
-
Breaking changes might not follow SemVer, please pin Vitest's version when using it.[39m
|
|
7
|
-
|
|
8
|
-
[1m[46m RUN [49m[22m [36mv3.2.6 [39m[90m/home/runner/work/monorepo-internal/monorepo-internal/tooling-configs/vitest[39m
|
|
9
|
-
|
|
10
|
-
[32m✓[39m test/index.test.ts [2m([22m[2m2 tests[22m[2m)[22m[32m 3[2mms[22m[39m
|
|
11
|
-
[32m✓[39m [44m[1m TS [22m[49m test/index.test.ts [2m([22m[2m2 tests[22m[2m)[22m
|
|
12
|
-
|
|
13
|
-
[2m Test Files [22m [1m[32m2 passed[39m[22m[90m (2)[39m
|
|
14
|
-
[2m Tests [22m [1m[32m4 passed[39m[22m[90m (4)[39m
|
|
15
|
-
[2mType Errors [22m [2mno errors[22m
|
|
16
|
-
[2m Start at [22m 19:22:17
|
|
17
|
-
[2m Duration [22m 1.65s[2m (transform 24ms, setup 0ms, collect 131ms, tests 3ms, environment 0ms, prepare 159ms, typecheck 1.22s)[22m
|
|
18
|
-
|