test: migrate to Vitest inline projects

This commit is contained in:
Ari Perkkiö 2025-06-28 09:43:05 +03:00
parent ba391f5fdf
commit 98f70ad0e2
6 changed files with 161 additions and 114 deletions

View File

@ -17,11 +17,11 @@
"format": "prettier --write --cache .",
"format-check": "prettier --check --cache .",
"test": "vitest",
"test-unit": "vitest --project unit",
"test-unit": "vitest --project unit*",
"test-e2e": "node scripts/build.js vue -f global -d && vitest --project e2e",
"test-dts": "run-s build-dts test-dts-only",
"test-dts-only": "tsc -p packages-private/dts-built-test/tsconfig.json && tsc -p ./packages-private/dts-test/tsconfig.test.json",
"test-coverage": "vitest run --project unit --coverage",
"test-coverage": "vitest run --project unit* --coverage",
"prebench": "node scripts/build.js -pf esm-browser reactivity",
"prebench-compare": "node scripts/build.js -pf esm-browser reactivity",
"bench": "vitest bench --project=unit --outputJson=temp/bench.json",
@ -74,7 +74,7 @@
"@types/node": "^22.15.32",
"@types/semver": "^7.7.0",
"@types/serve-handler": "^6.1.4",
"@vitest/coverage-v8": "^3.1.4",
"@vitest/coverage-v8": "^3.2.4",
"@vitest/eslint-plugin": "^1.2.1",
"@vue/consolidate": "1.0.0",
"conventional-changelog-cli": "^5.0.0",
@ -110,6 +110,6 @@
"typescript": "~5.6.2",
"typescript-eslint": "^8.32.1",
"vite": "catalog:",
"vitest": "^3.1.4"
"vitest": "^3.2.4"
}
}

View File

@ -69,11 +69,11 @@ importers:
specifier: ^6.1.4
version: 6.1.4
'@vitest/coverage-v8':
specifier: ^3.1.4
version: 3.1.4(vitest@3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))
specifier: ^3.2.4
version: 3.2.4(vitest@3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))
'@vitest/eslint-plugin':
specifier: ^1.2.1
version: 1.2.1(eslint@9.27.0)(typescript@5.6.3)(vitest@3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))
version: 1.2.1(eslint@9.27.0)(typescript@5.6.3)(vitest@3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))
'@vue/consolidate':
specifier: 1.0.0
version: 1.0.0
@ -175,10 +175,10 @@ importers:
version: 8.32.1(eslint@9.27.0)(typescript@5.6.3)
vite:
specifier: 'catalog:'
version: 5.4.19(@types/node@22.15.32)(sass@1.89.2)
version: 5.4.15(@types/node@22.15.32)(sass@1.89.2)
vitest:
specifier: ^3.1.4
version: 3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2)
specifier: ^3.2.4
version: 3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2)
packages-private/dts-built-test:
dependencies:
@ -1258,6 +1258,12 @@ packages:
'@tybys/wasm-util@0.9.0':
resolution: {integrity: sha512-6+7nlbMVX/PVDCwaIQ8nTOPveOcFLSt8GcXdx8hD0bt39uWxYT88uXzqTd4fTvqta7oeUJqudepapKNt2DYJFw==}
'@types/chai@5.2.2':
resolution: {integrity: sha512-8kB30R7Hwqf40JPiKhVzodJs2Qc1ZJ5zuT3uzw5Hq/dhNCl3G3l83jfpdI1e20BP348+fV7VIL/+FxaXkqBmWg==}
'@types/deep-eql@4.0.2':
resolution: {integrity: sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==}
'@types/estree@1.0.7':
resolution: {integrity: sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==}
@ -1430,11 +1436,11 @@ packages:
vite: ^5.0.0 || ^6.0.0
vue: ^3.2.25
'@vitest/coverage-v8@3.1.4':
resolution: {integrity: sha512-G4p6OtioySL+hPV7Y6JHlhpsODbJzt1ndwHAFkyk6vVjpK03PFsKnauZIzcd0PrK4zAbc5lc+jeZ+eNGiMA+iw==}
'@vitest/coverage-v8@3.2.4':
resolution: {integrity: sha512-EyF9SXU6kS5Ku/U82E259WSnvg6c8KTjppUncuNdm5QHpe17mwREHnjDzozC8x9MZ0xfBUFSaLkRv4TMA75ALQ==}
peerDependencies:
'@vitest/browser': 3.1.4
vitest: 3.1.4
'@vitest/browser': 3.2.4
vitest: 3.2.4
peerDependenciesMeta:
'@vitest/browser':
optional: true
@ -1451,34 +1457,34 @@ packages:
vitest:
optional: true
'@vitest/expect@3.1.4':
resolution: {integrity: sha512-xkD/ljeliyaClDYqHPNCiJ0plY5YIcM0OlRiZizLhlPmpXWpxnGMyTZXOHFhFeG7w9P5PBeL4IdtJ/HeQwTbQA==}
'@vitest/expect@3.2.4':
resolution: {integrity: sha512-Io0yyORnB6sikFlt8QW5K7slY4OjqNX9jmJQ02QDda8lyM6B5oNgVWoSoKPac8/kgnCUzuHQKrSLtu/uOqqrig==}
'@vitest/mocker@3.1.4':
resolution: {integrity: sha512-8IJ3CvwtSw/EFXqWFL8aCMu+YyYXG2WUSrQbViOZkWTKTVicVwZ/YiEZDSqD00kX+v/+W+OnxhNWoeVKorHygA==}
'@vitest/mocker@3.2.4':
resolution: {integrity: sha512-46ryTE9RZO/rfDd7pEqFl7etuyzekzEhUbTW3BvmeO/BcCMEgq59BKhek3dXDWgAj4oMK6OZi+vRr1wPW6qjEQ==}
peerDependencies:
msw: ^2.4.9
vite: ^5.0.0 || ^6.0.0
vite: ^5.0.0 || ^6.0.0 || ^7.0.0-0
peerDependenciesMeta:
msw:
optional: true
vite:
optional: true
'@vitest/pretty-format@3.1.4':
resolution: {integrity: sha512-cqv9H9GvAEoTaoq+cYqUTCGscUjKqlJZC7PRwY5FMySVj5J+xOm1KQcCiYHJOEzOKRUhLH4R2pTwvFlWCEScsg==}
'@vitest/pretty-format@3.2.4':
resolution: {integrity: sha512-IVNZik8IVRJRTr9fxlitMKeJeXFFFN0JaB9PHPGQ8NKQbGpfjlTx9zO4RefN8gp7eqjNy8nyK3NZmBzOPeIxtA==}
'@vitest/runner@3.1.4':
resolution: {integrity: sha512-djTeF1/vt985I/wpKVFBMWUlk/I7mb5hmD5oP8K9ACRmVXgKTae3TUOtXAEBfslNKPzUQvnKhNd34nnRSYgLNQ==}
'@vitest/runner@3.2.4':
resolution: {integrity: sha512-oukfKT9Mk41LreEW09vt45f8wx7DordoWUZMYdY/cyAk7w5TWkTRCNZYF7sX7n2wB7jyGAl74OxgwhPgKaqDMQ==}
'@vitest/snapshot@3.1.4':
resolution: {integrity: sha512-JPHf68DvuO7vilmvwdPr9TS0SuuIzHvxeaCkxYcCD4jTk67XwL45ZhEHFKIuCm8CYstgI6LZ4XbwD6ANrwMpFg==}
'@vitest/snapshot@3.2.4':
resolution: {integrity: sha512-dEYtS7qQP2CjU27QBC5oUOxLE/v5eLkGqPE0ZKEIDGMs4vKWe7IjgLOeauHsR0D5YuuycGRO5oSRXnwnmA78fQ==}
'@vitest/spy@3.1.4':
resolution: {integrity: sha512-Xg1bXhu+vtPXIodYN369M86K8shGLouNjoVI78g8iAq2rFoHFdajNvJJ5A/9bPMFcfQqdaCpOgWKEoMQg/s0Yg==}
'@vitest/spy@3.2.4':
resolution: {integrity: sha512-vAfasCOe6AIK70iP5UD11Ac4siNUNJ9i/9PZ3NKx07sG6sUxeag1LWdNrMWeKKYBLlzuK+Gn65Yd5nyL6ds+nw==}
'@vitest/utils@3.1.4':
resolution: {integrity: sha512-yriMuO1cfFhmiGc8ataN51+9ooHRuURdfAZfwFd3usWynjzpLslZdYnRegTv32qdgtJTsj15FoeZe2g15fY1gg==}
'@vitest/utils@3.2.4':
resolution: {integrity: sha512-fB2V0JFrQSMsCo9HiSq3Ezpdv4iYaXRG1Sx8edX3MwxfyNn83mKiGzOcH+Fkxt4MHxr3y42fQi1oeAInqgX2QA==}
'@vue/consolidate@1.0.0':
resolution: {integrity: sha512-oTyUE+QHIzLw2PpV14GD/c7EohDyP64xCniWTcqcEmTd699eFqTIwOmtDYjcO1j3QgdXoJEoWv1/cCdLrRoOfg==}
@ -1575,6 +1581,9 @@ packages:
resolution: {integrity: sha512-x1FCFnFifvYDDzTaLII71vG5uvDwgtmDTEVWAxrgeiR8VjMONcCXJx7E+USjDtHlwFmt9MysbqgF9b9Vjr6w+w==}
engines: {node: '>=4'}
ast-v8-to-istanbul@0.3.3:
resolution: {integrity: sha512-MuXMrSLVVoA6sYN/6Hke18vMzrT4TZNbZIj/hvh0fnYFpO+/kFXcLIaiPwXXWaQUPg4yJD8fj+lfJ7/1EBconw==}
b4a@1.6.6:
resolution: {integrity: sha512-5Tk1HLk6b6ctmjIkAcU/Ujv/1WqiDl0F0JdRCR80VsOcUlHcu7pWeWRlOqQLHfDEsVx9YH/aif5AG4ehoCtTmg==}
@ -2440,6 +2449,9 @@ packages:
js-tokens@4.0.0:
resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==}
js-tokens@9.0.1:
resolution: {integrity: sha512-mxa9E9ITFOt0ban3j6L5MpjwegGz6lBQmM1IJkWeBZGcMxto50+eWdjC/52xDbS2vy0k7vIMK0Fe2wfL9OQSpQ==}
js-yaml@4.1.0:
resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==}
hasBin: true
@ -2534,6 +2546,9 @@ packages:
loupe@3.1.3:
resolution: {integrity: sha512-kkIp7XSkP78ZxJEsSxW3712C6teJVoeHHwgo9zJ380de7IYyJ2ISlxojcH2pC5OFLewESmnRi/+XCDIEEVyoug==}
loupe@3.1.4:
resolution: {integrity: sha512-wJzkKwJrheKtknCOKNEtDK4iqg/MxmZheEMtSTYvnzRdEYaZzmgH976nenp8WdJRdx5Vc1X/9MO0Oszl6ezeXg==}
lru-cache@10.1.0:
resolution: {integrity: sha512-/1clY/ui8CzjKFyjdvwPWJUYKiFVXG2I2cY0ssG7h4+hwk+XOIX7ZSG9Q7TW8TW3Kp3BUSqgFWBLgL4PJ+Blag==}
engines: {node: 14 || >=16.14}
@ -3208,6 +3223,9 @@ packages:
resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==}
engines: {node: '>=8'}
strip-literal@3.0.0:
resolution: {integrity: sha512-TcccoMhJOM3OebGhSBEmp3UZ2SfDMZUEBdRA/9ynfLi8yYajyWX3JiXArcJt4Umh4vISpspkQIY8ZZoCqjbviA==}
supports-color@7.2.0:
resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==}
engines: {node: '>=8'}
@ -3246,20 +3264,20 @@ packages:
tinyexec@0.3.2:
resolution: {integrity: sha512-KQQR9yN7R5+OSwaK0XQoj22pwHoTlgYqmUscPYoknOoWCWfj/5/ABTMRi69FrKU5ffPVh5QcFikpWJI/P1ocHA==}
tinyglobby@0.2.13:
resolution: {integrity: sha512-mEwzpUgrLySlveBwEVDMKk5B57bhLPYovRfPAXD5gA/98Opn0rCDj3GtLwFvCvH5RK9uPCExUROW5NjDwvqkxw==}
tinyglobby@0.2.14:
resolution: {integrity: sha512-tX5e7OM1HnYr2+a2C/4V0htOcSQcoSTH9KgJnVvNm5zm/cyEWKJ7j7YutsH9CxMdtOkkLFy2AHrMci9IM8IPZQ==}
engines: {node: '>=12.0.0'}
tinypool@1.0.2:
resolution: {integrity: sha512-al6n+QEANGFOMf/dmUMsuS5/r9B06uwlyNjZZql/zv8J7ybHCgoihBNORZCY2mzUuAnomQa2JdhyHKzZxPCrFA==}
tinypool@1.1.1:
resolution: {integrity: sha512-Zba82s87IFq9A9XmjiX5uZA/ARWDrB03OHlq+Vw1fSdt0I+4/Kutwy8BP4Y/y/aORMo61FQ0vIb5j44vSo5Pkg==}
engines: {node: ^18.0.0 || >=20.0.0}
tinyrainbow@2.0.0:
resolution: {integrity: sha512-op4nsTR47R6p0vMUUoYl/a+ljLFVtlfaXkLQmqfLR1qHma1h/ysYk4hEXZ880bf2CYgTskvTa/e196Vd5dDQXw==}
engines: {node: '>=14.0.0'}
tinyspy@3.0.2:
resolution: {integrity: sha512-n1cw8k1k0x4pgA2+9XrOkFydTerNcJ1zWCO5Nn9scWHTD+5tp8dghT2x1uduQePZTZgd3Tupf+x9BxJjeJi77Q==}
tinyspy@4.0.3:
resolution: {integrity: sha512-t2T/WLB2WRgZ9EpE4jgPJ9w+i66UZfDc8wHh0xrwiRNN+UwH98GIJkTeZqX9rg0i0ptwzqW+uYeIF0T4F8LR7A==}
engines: {node: '>=14.0.0'}
tldts-core@6.1.86:
@ -3363,8 +3381,8 @@ packages:
resolution: {integrity: sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==}
engines: {node: '>= 0.8'}
vite-node@3.1.4:
resolution: {integrity: sha512-6enNwYnpyDo4hEgytbmc6mYWHXDHYEn0D1/rw4Q+tnHUGtKTJsn8T1YkX6Q18wI5LCrS8CTYlBaiCqxOy2kvUA==}
vite-node@3.2.4:
resolution: {integrity: sha512-EbKSKh+bh1E1IFxeO0pg1n4dvoOTt0UDiXMd/qn++r98+jPO1xtJilvXldeuQ8giIB5IkpjCgMleHMNEsGH6pg==}
engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0}
hasBin: true
@ -3430,16 +3448,16 @@ packages:
terser:
optional: true
vitest@3.1.4:
resolution: {integrity: sha512-Ta56rT7uWxCSJXlBtKgIlApJnT6e6IGmTYxYcmxjJ4ujuZDI59GUQgVDObXXJujOmPDBYXHK1qmaGtneu6TNIQ==}
vitest@3.2.4:
resolution: {integrity: sha512-LUCP5ev3GURDysTWiP47wRRUpLKMOfPh+yKTx3kVIEiu5KOMeqzpnYNsKyOoVrULivR8tLcks4+lga33Whn90A==}
engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0}
hasBin: true
peerDependencies:
'@edge-runtime/vm': '*'
'@types/debug': ^4.1.12
'@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0
'@vitest/browser': 3.1.4
'@vitest/ui': 3.1.4
'@vitest/browser': 3.2.4
'@vitest/ui': 3.2.4
happy-dom: '*'
jsdom: '*'
peerDependenciesMeta:
@ -3824,7 +3842,7 @@ snapshots:
'@eslint/config-array@0.20.0':
dependencies:
'@eslint/object-schema': 2.1.6
debug: 4.4.0
debug: 4.4.1
minimatch: 3.1.2
transitivePeerDependencies:
- supports-color
@ -3838,7 +3856,7 @@ snapshots:
'@eslint/eslintrc@3.3.1':
dependencies:
ajv: 6.12.6
debug: 4.4.0
debug: 4.4.1
espree: 10.3.0
globals: 14.0.0
ignore: 5.3.2
@ -4174,6 +4192,12 @@ snapshots:
tslib: 2.8.1
optional: true
'@types/chai@5.2.2':
dependencies:
'@types/deep-eql': 4.0.2
'@types/deep-eql@4.0.2': {}
'@types/estree@1.0.7': {}
'@types/estree@1.0.8': {}
@ -4338,11 +4362,12 @@ snapshots:
vite: 5.4.15(@types/node@22.15.32)(sass@1.89.2)
vue: link:packages/vue
'@vitest/coverage-v8@3.1.4(vitest@3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))':
'@vitest/coverage-v8@3.2.4(vitest@3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))':
dependencies:
'@ampproject/remapping': 2.3.0
'@bcoe/v8-coverage': 1.0.2
debug: 4.4.0
ast-v8-to-istanbul: 0.3.3
debug: 4.4.1
istanbul-lib-coverage: 3.2.2
istanbul-lib-report: 3.0.1
istanbul-lib-source-maps: 5.0.6
@ -4352,58 +4377,60 @@ snapshots:
std-env: 3.9.0
test-exclude: 7.0.1
tinyrainbow: 2.0.0
vitest: 3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2)
vitest: 3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2)
transitivePeerDependencies:
- supports-color
'@vitest/eslint-plugin@1.2.1(eslint@9.27.0)(typescript@5.6.3)(vitest@3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))':
'@vitest/eslint-plugin@1.2.1(eslint@9.27.0)(typescript@5.6.3)(vitest@3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2))':
dependencies:
'@typescript-eslint/utils': 8.32.1(eslint@9.27.0)(typescript@5.6.3)
eslint: 9.27.0
optionalDependencies:
typescript: 5.6.3
vitest: 3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2)
vitest: 3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2)
transitivePeerDependencies:
- supports-color
'@vitest/expect@3.1.4':
'@vitest/expect@3.2.4':
dependencies:
'@vitest/spy': 3.1.4
'@vitest/utils': 3.1.4
'@types/chai': 5.2.2
'@vitest/spy': 3.2.4
'@vitest/utils': 3.2.4
chai: 5.2.0
tinyrainbow: 2.0.0
'@vitest/mocker@3.1.4(vite@5.4.19(@types/node@22.15.32)(sass@1.89.2))':
'@vitest/mocker@3.2.4(vite@5.4.19(@types/node@22.15.32)(sass@1.89.2))':
dependencies:
'@vitest/spy': 3.1.4
'@vitest/spy': 3.2.4
estree-walker: 3.0.3
magic-string: 0.30.17
optionalDependencies:
vite: 5.4.19(@types/node@22.15.32)(sass@1.89.2)
'@vitest/pretty-format@3.1.4':
'@vitest/pretty-format@3.2.4':
dependencies:
tinyrainbow: 2.0.0
'@vitest/runner@3.1.4':
'@vitest/runner@3.2.4':
dependencies:
'@vitest/utils': 3.1.4
'@vitest/utils': 3.2.4
pathe: 2.0.3
strip-literal: 3.0.0
'@vitest/snapshot@3.1.4':
'@vitest/snapshot@3.2.4':
dependencies:
'@vitest/pretty-format': 3.1.4
'@vitest/pretty-format': 3.2.4
magic-string: 0.30.17
pathe: 2.0.3
'@vitest/spy@3.1.4':
'@vitest/spy@3.2.4':
dependencies:
tinyspy: 3.0.2
tinyspy: 4.0.3
'@vitest/utils@3.1.4':
'@vitest/utils@3.2.4':
dependencies:
'@vitest/pretty-format': 3.1.4
loupe: 3.1.3
'@vitest/pretty-format': 3.2.4
loupe: 3.1.4
tinyrainbow: 2.0.0
'@vue/consolidate@1.0.0': {}
@ -4481,6 +4508,12 @@ snapshots:
dependencies:
tslib: 2.8.1
ast-v8-to-istanbul@0.3.3:
dependencies:
'@jridgewell/trace-mapping': 0.3.25
estree-walker: 3.0.3
js-tokens: 9.0.1
b4a@1.6.6: {}
babel-walk@3.0.0-canary-5:
@ -5035,7 +5068,7 @@ snapshots:
estree-walker@3.0.3:
dependencies:
'@types/estree': 1.0.7
'@types/estree': 1.0.8
esutils@2.0.3: {}
@ -5386,7 +5419,7 @@ snapshots:
istanbul-lib-source-maps@5.0.6:
dependencies:
'@jridgewell/trace-mapping': 0.3.25
debug: 4.4.0
debug: 4.4.1
istanbul-lib-coverage: 3.2.2
transitivePeerDependencies:
- supports-color
@ -5412,6 +5445,8 @@ snapshots:
js-tokens@4.0.0: {}
js-tokens@9.0.1: {}
js-yaml@4.1.0:
dependencies:
argparse: 2.0.1
@ -5538,6 +5573,8 @@ snapshots:
loupe@3.1.3: {}
loupe@3.1.4: {}
lru-cache@10.1.0: {}
lru-cache@10.4.3: {}
@ -6271,6 +6308,10 @@ snapshots:
strip-json-comments@3.1.1: {}
strip-literal@3.0.0:
dependencies:
js-tokens: 9.0.1
supports-color@7.2.0:
dependencies:
has-flag: 4.0.0
@ -6313,16 +6354,16 @@ snapshots:
tinyexec@0.3.2: {}
tinyglobby@0.2.13:
tinyglobby@0.2.14:
dependencies:
fdir: 6.4.4(picomatch@4.0.2)
picomatch: 4.0.2
tinypool@1.0.2: {}
tinypool@1.1.1: {}
tinyrainbow@2.0.0: {}
tinyspy@3.0.2: {}
tinyspy@4.0.3: {}
tldts-core@6.1.86: {}
@ -6428,7 +6469,7 @@ snapshots:
vary@1.1.2: {}
vite-node@3.1.4(@types/node@22.15.32)(sass@1.89.2):
vite-node@3.2.4(@types/node@22.15.32)(sass@1.89.2):
dependencies:
cac: 6.7.14
debug: 4.4.1
@ -6466,28 +6507,30 @@ snapshots:
fsevents: 2.3.3
sass: 1.89.2
vitest@3.1.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2):
vitest@3.2.4(@types/node@22.15.32)(jsdom@26.1.0)(sass@1.89.2):
dependencies:
'@vitest/expect': 3.1.4
'@vitest/mocker': 3.1.4(vite@5.4.19(@types/node@22.15.32)(sass@1.89.2))
'@vitest/pretty-format': 3.1.4
'@vitest/runner': 3.1.4
'@vitest/snapshot': 3.1.4
'@vitest/spy': 3.1.4
'@vitest/utils': 3.1.4
'@types/chai': 5.2.2
'@vitest/expect': 3.2.4
'@vitest/mocker': 3.2.4(vite@5.4.19(@types/node@22.15.32)(sass@1.89.2))
'@vitest/pretty-format': 3.2.4
'@vitest/runner': 3.2.4
'@vitest/snapshot': 3.2.4
'@vitest/spy': 3.2.4
'@vitest/utils': 3.2.4
chai: 5.2.0
debug: 4.4.0
debug: 4.4.1
expect-type: 1.2.1
magic-string: 0.30.17
pathe: 2.0.3
picomatch: 4.0.2
std-env: 3.9.0
tinybench: 2.9.0
tinyexec: 0.3.2
tinyglobby: 0.2.13
tinypool: 1.0.2
tinyglobby: 0.2.14
tinypool: 1.1.1
tinyrainbow: 2.0.0
vite: 5.4.19(@types/node@22.15.32)(sass@1.89.2)
vite-node: 3.1.4(@types/node@22.15.32)(sass@1.89.2)
vite-node: 3.2.4(@types/node@22.15.32)(sass@1.89.2)
why-is-node-running: 2.3.0
optionalDependencies:
'@types/node': 22.15.32

View File

@ -1,4 +1,4 @@
import { defineConfig } from 'vitest/config'
import { configDefaults, defineConfig } from 'vitest/config'
import { entries } from './scripts/aliases.js'
export default defineConfig({
@ -25,9 +25,6 @@ export default defineConfig({
globals: true,
pool: 'threads',
setupFiles: 'scripts/setup-vitest.ts',
environmentMatchGlobs: [
['packages/{vue,vue-compat,runtime-dom}/**', 'jsdom'],
],
sequence: {
hooks: 'list',
},
@ -49,5 +46,41 @@ export default defineConfig({
'packages/runtime-dom/src/components/Transition*',
],
},
projects: [
{
extends: true,
test: {
name: 'unit',
exclude: [
...configDefaults.exclude,
'**/e2e/**',
'**/{vue,vue-compat,runtime-dom}/**',
],
},
},
{
extends: true,
test: {
name: 'unit-jsdom',
include: ['packages/{vue,vue-compat,runtime-dom}/**/*.{test,spec}.*'],
exclude: [...configDefaults.exclude, '**/e2e/**'],
environment: 'jsdom',
},
},
{
extends: true,
test: {
name: 'e2e',
environment: 'jsdom',
poolOptions: {
threads: {
singleThread: !!process.env.CI,
},
},
include: ['packages/vue/__tests__/e2e/*.spec.ts'],
},
},
],
},
})

View File

@ -1,14 +0,0 @@
import { mergeConfig } from 'vitest/config'
import config from './vitest.config'
export default mergeConfig(config, {
test: {
name: 'e2e',
poolOptions: {
threads: {
singleThread: !!process.env.CI,
},
},
include: ['packages/vue/__tests__/e2e/*.spec.ts'],
},
})

View File

@ -1,9 +0,0 @@
import { configDefaults, mergeConfig } from 'vitest/config'
import config from './vitest.config'
export default mergeConfig(config, {
test: {
name: 'unit',
exclude: [...configDefaults.exclude, '**/e2e/**'],
},
})

View File

@ -1,6 +0,0 @@
import { defineWorkspace } from 'vitest/config'
export default defineWorkspace([
'./vitest.unit.config.ts',
'./vitest.e2e.config.ts',
])