diff --git a/.c8rc.json b/.c8rc.json deleted file mode 100644 index 599b524..0000000 --- a/.c8rc.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "reporter": [ - "html", - "lcovonly", - "text" - ] -} diff --git a/.mocharc.json b/.mocharc.json deleted file mode 100644 index 5c909bb..0000000 --- a/.mocharc.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "check-leaks": true, - "throw-deprecation": true, - "trace-deprecation": true, - "trace-warnings": true, - "use-strict": true -} diff --git a/package-lock.json b/package-lock.json index 0bbe645..be19737 100644 --- a/package-lock.json +++ b/package-lock.json @@ -30,8 +30,8 @@ }, "devDependencies": { "@babel/parser": "^7.29.3", - "c8": "^11.0.0", - "uvu": "^0.5.6", + "@vitest/coverage-v8": "^4.1.7", + "vitest": "^4.1.7", "xo": "^2.0.2" }, "engines": { @@ -852,16 +852,6 @@ "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/@istanbuljs/schema": { - "version": "0.1.6", - "resolved": "https://registry.npmjs.org/@istanbuljs/schema/-/schema-0.1.6.tgz", - "integrity": "sha512-+Sg6GCR/wy1oSmQDFq4LQDAhm3ETKnorxN+y5nbLULOR3P0c14f2Wurzj3/xqPXtasLFfHd5iRFQ7AJt4KH2cw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/@jridgewell/gen-mapping": { "version": "0.3.13", "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.13.tgz", @@ -962,6 +952,16 @@ "node": ">= 8" } }, + "node_modules/@oxc-project/types": { + "version": "0.132.0", + "resolved": "https://registry.npmjs.org/@oxc-project/types/-/types-0.132.0.tgz", + "integrity": "sha512-FESMOxil5Se014ui/Eq8fT5uHJo6nIRwH0PfJrZJXs6Gek3ZVFOrpUv3YIZT20m+extU98Hg1Ym72U58rlsxUQ==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/Boshen" + } + }, "node_modules/@package-json/types": { "version": "0.0.12", "resolved": "https://registry.npmjs.org/@package-json/types/-/types-0.0.12.tgz", @@ -982,6 +982,307 @@ "url": "https://opencollective.com/pkgr" } }, + "node_modules/@rolldown/binding-android-arm64": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-android-arm64/-/binding-android-arm64-1.0.2.tgz", + "integrity": "sha512-ZS4D1JPGn/MYQN/SYDWftIE/nVsM8j/AFOYEzAoOE2O3NktQOZru+/vYXGbR/qtdLdIfGCP0lcoJiYVzsEz+iQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-darwin-arm64": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-darwin-arm64/-/binding-darwin-arm64-1.0.2.tgz", + "integrity": "sha512-vdFA9+C/rekyGce7WqHs/xoT0ioZEWaOFyZLIV1mEeNFaFDUQrPIo8Vs2GvJ6eetb3rzDUtUBgzto3ExpXJB3w==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-darwin-x64": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-darwin-x64/-/binding-darwin-x64-1.0.2.tgz", + "integrity": "sha512-BewSOwTHazv77DTYiAZXSqqKZ4KP/KonFisDMVU7PImxoWfB2aepnPhd2E4SWz3zDzYgDNbs6jBmTdgNnF02GA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-freebsd-x64": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-freebsd-x64/-/binding-freebsd-x64-1.0.2.tgz", + "integrity": "sha512-m41o7M0YWtUdqk61Tb+jnKb2rN++iRdIASlExkUoKfIAH30DOHCB8fVLzSUpbWHHU8esmEioY62PxzexE8MBuA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-arm-gnueabihf": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm-gnueabihf/-/binding-linux-arm-gnueabihf-1.0.2.tgz", + "integrity": "sha512-jcojB9H7W/jS29pMKWAK1N+fU99vXodHDTatS3b3y/XSOCiHo0kkA74pL3jJmkoQtYpOCxDvaKs1fo2Ij/1X5w==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-arm64-gnu": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm64-gnu/-/binding-linux-arm64-gnu-1.0.2.tgz", + "integrity": "sha512-1jn6qDU5iiOgFgygDzKUuKP0maTi0/f1+sBLgvij/76C77Nm3ts6ufz9Bjg5q5dduxiUIxtq86JIoBvo1xQ4Ig==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-arm64-musl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-arm64-musl/-/binding-linux-arm64-musl-1.0.2.tgz", + "integrity": "sha512-QVLO/czFMdoMFSqlX3bcswcJNm/23r+qoa/jgtmFc/qEp6/jXmIkDjF/XIo8dPfGaiwy1xfQn8o77L79GeXFgw==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-ppc64-gnu": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-ppc64-gnu/-/binding-linux-ppc64-gnu-1.0.2.tgz", + "integrity": "sha512-hgO5Abm0w5UL6FEa2iFnZqo2KlK7TQ5QhV5x09hujBf7t5KzHQ1VmfPuTpqRy/rNlSxua3eWH374xxiVrP+lcA==", + "cpu": [ + "ppc64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-s390x-gnu": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-s390x-gnu/-/binding-linux-s390x-gnu-1.0.2.tgz", + "integrity": "sha512-fy8rXxuYEu602abC8MUNaPjYLIFzReOaEIEMKMUa0rFEUxNpVXhs15KSSQ4qlqSaM7B6rcj9rDZgADh/IGDzLQ==", + "cpu": [ + "s390x" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-x64-gnu": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-x64-gnu/-/binding-linux-x64-gnu-1.0.2.tgz", + "integrity": "sha512-0+bOkiQ779+r1WpoHOWHqncvyySci0vKph+myNDYb+im6meJAzHQXay6oEgnkHuUGouM1LKTZwqKpBow6Kj7CQ==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-linux-x64-musl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-linux-x64-musl/-/binding-linux-x64-musl-1.0.2.tgz", + "integrity": "sha512-mjSkrzZK5Qsl0a9d1JgILOiuZOSDTVdKENcSXBoqbzSrspLR/4/IRVDo5wd2GgZjNss/viBFJdeq+j7qH2nypw==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-openharmony-arm64": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-openharmony-arm64/-/binding-openharmony-arm64-1.0.2.tgz", + "integrity": "sha512-1v5vHasdfQAZoEHakBV72LIFAC9JjnymsiKxp+GEr/ma3+NJCPSaYK+qavInOovJkgwFrs7GccX2d6IgDA3Z5w==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-wasm32-wasi": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-wasm32-wasi/-/binding-wasm32-wasi-1.0.2.tgz", + "integrity": "sha512-mb1VobWn6NheziTk5/WEaR6AKVbrwT5sOi6C7zk3gy/pD1qtJfU1j4PgTo2NJnOtbL9Dl3Aeei8w9jJ7qC2jZQ==", + "cpu": [ + "wasm32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "@emnapi/core": "1.10.0", + "@emnapi/runtime": "1.10.0", + "@napi-rs/wasm-runtime": "^1.1.4" + }, + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-wasm32-wasi/node_modules/@napi-rs/wasm-runtime": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/@napi-rs/wasm-runtime/-/wasm-runtime-1.1.4.tgz", + "integrity": "sha512-3NQNNgA1YSlJb/kMH1ildASP9HW7/7kYnRI2szWJaofaS1hWmbGI4H+d3+22aGzXXN9IJ+n+GiFVcGipJP18ow==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "@tybys/wasm-util": "^0.10.1" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/Brooooooklyn" + }, + "peerDependencies": { + "@emnapi/core": "^1.7.1", + "@emnapi/runtime": "^1.7.1" + } + }, + "node_modules/@rolldown/binding-win32-arm64-msvc": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-win32-arm64-msvc/-/binding-win32-arm64-msvc-1.0.2.tgz", + "integrity": "sha512-SqKonF56vA/L2yHwHYcEp2P34URpOZ7d1fS635cTkpDnUtEGdUbhI6NzsPdqeSWvAAeGDrxjWjNmibDIdFf9/A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/binding-win32-x64-msvc": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@rolldown/binding-win32-x64-msvc/-/binding-win32-x64-msvc-1.0.2.tgz", + "integrity": "sha512-v7qRI7gXLRINcOGXt+7YmAZ6iFuyZVMIoXAxhd8oP+DR9dLfL9GfNIx7PLMxmhZdvq8waUJBQiWN9EKNy+TRBQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": "^20.19.0 || >=22.12.0" + } + }, + "node_modules/@rolldown/pluginutils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@rolldown/pluginutils/-/pluginutils-1.0.1.tgz", + "integrity": "sha512-2j9bGt5Jh8hj+vPtgzPtl72j0yRxHAyumoo6TNfAjsLB04UtpSvPbPcDcBMxz7n+9CYB0c1GxQFxYRg2jimqGw==", + "dev": true, + "license": "MIT" + }, "node_modules/@sec-ant/readable-stream": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/@sec-ant/readable-stream/-/readable-stream-0.4.1.tgz", @@ -1015,6 +1316,13 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/@standard-schema/spec": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@standard-schema/spec/-/spec-1.1.0.tgz", + "integrity": "sha512-l2aFy5jALhniG5HgqrD6jXLi/rUWrKvqN/qJx6yoJsgKhblVd+iqqU4RCXavm/jPityDo5TCvKMnpjKnOriy0w==", + "dev": true, + "license": "MIT" + }, "node_modules/@stylistic/eslint-plugin": { "version": "5.10.0", "resolved": "https://registry.npmjs.org/@stylistic/eslint-plugin/-/eslint-plugin-5.10.0.tgz", @@ -1078,6 +1386,24 @@ "tslib": "^2.4.0" } }, + "node_modules/@types/chai": { + "version": "5.2.3", + "resolved": "https://registry.npmjs.org/@types/chai/-/chai-5.2.3.tgz", + "integrity": "sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/deep-eql": "*", + "assertion-error": "^2.0.1" + } + }, + "node_modules/@types/deep-eql": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/@types/deep-eql/-/deep-eql-4.0.2.tgz", + "integrity": "sha512-c9h9dVVMigMPc4bwTvC5dxqtqJZwQPePsWjPlpSOnojbor6pGqdk541lfA7AqFQr5pB1BRdq0juY9db81BwyFw==", + "dev": true, + "license": "MIT" + }, "node_modules/@types/eslint": { "version": "9.6.1", "resolved": "https://registry.npmjs.org/@types/eslint/-/eslint-9.6.1.tgz", @@ -1103,13 +1429,6 @@ "dev": true, "license": "MIT" }, - "node_modules/@types/istanbul-lib-coverage": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.6.tgz", - "integrity": "sha512-2QF/t/auWm0lsy8XtKVPG19v3sSOQlJe/YHZgfjb/KBBHOGSV+J2q/S671rcq9uTBrLAXmZpqJiaQbMT+zNU1w==", - "dev": true, - "license": "MIT" - }, "node_modules/@types/json-schema": { "version": "7.0.15", "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", @@ -1625,6 +1944,160 @@ "win32" ] }, + "node_modules/@vitest/coverage-v8": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/coverage-v8/-/coverage-v8-4.1.7.tgz", + "integrity": "sha512-qsYPeXc5Q9dFLd1i8Ap+Bx8sQgcp+rFVQo4R0dDsWNBzl26ldVF1qOO+RL24K7FDrR6pA+50XedRLSoSG24bVQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@bcoe/v8-coverage": "^1.0.2", + "@vitest/utils": "4.1.7", + "ast-v8-to-istanbul": "^1.0.0", + "istanbul-lib-coverage": "^3.2.2", + "istanbul-lib-report": "^3.0.1", + "istanbul-reports": "^3.2.0", + "magicast": "^0.5.2", + "obug": "^2.1.1", + "std-env": "^4.0.0-rc.1", + "tinyrainbow": "^3.1.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "@vitest/browser": "4.1.7", + "vitest": "4.1.7" + }, + "peerDependenciesMeta": { + "@vitest/browser": { + "optional": true + } + } + }, + "node_modules/@vitest/expect": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/expect/-/expect-4.1.7.tgz", + "integrity": "sha512-1R+tw0ortHEbZDGMymm+pN7/AFQ/RkFFdtd7EN+VBpynKmLbP8A3rpEXdshBJ7+8hQ9zBJh/i1s0yKNtxAnU7w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@standard-schema/spec": "^1.1.0", + "@types/chai": "^5.2.2", + "@vitest/spy": "4.1.7", + "@vitest/utils": "4.1.7", + "chai": "^6.2.2", + "tinyrainbow": "^3.1.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "node_modules/@vitest/mocker": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/mocker/-/mocker-4.1.7.tgz", + "integrity": "sha512-vY7nuamKgfvpA1Koa3oYIw/k7D6kZnpGyNMZW8loow2bsBYla1TFdqTaXncWdRn4pgwNs+90RhnXhJScDwQeJA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/spy": "4.1.7", + "estree-walker": "^3.0.3", + "magic-string": "^0.30.21" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "msw": "^2.4.9", + "vite": "^6.0.0 || ^7.0.0 || ^8.0.0" + }, + "peerDependenciesMeta": { + "msw": { + "optional": true + }, + "vite": { + "optional": true + } + } + }, + "node_modules/@vitest/mocker/node_modules/estree-walker": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.3.tgz", + "integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "^1.0.0" + } + }, + "node_modules/@vitest/pretty-format": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/pretty-format/-/pretty-format-4.1.7.tgz", + "integrity": "sha512-umgCarTOYQWIaDMvGDRZij+6b9oVeLIyJzfN+AS88e0ZOU3QTgNNSTtjQOpcvWr3np1N0j4WgZj+sb3oYBDscw==", + "dev": true, + "license": "MIT", + "dependencies": { + "tinyrainbow": "^3.1.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "node_modules/@vitest/runner": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/runner/-/runner-4.1.7.tgz", + "integrity": "sha512-BapjmAQ2aI78WdMEfeUWivnfVzB+VPGwWRQcJE0OUq7qEeEcBsCSf+0T5iREBNE5nBb4wA5Ya0W6IA+sghdEFw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/utils": "4.1.7", + "pathe": "^2.0.3" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "node_modules/@vitest/snapshot": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/snapshot/-/snapshot-4.1.7.tgz", + "integrity": "sha512-ZacLzja+TmJeZ1h14xW2FB/WpeimUD3haBXQPyJqxvo8jQTmfeA8zv58mtjN2C7EHXZDYVcVYdYmAxjkWVvKCw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/pretty-format": "4.1.7", + "@vitest/utils": "4.1.7", + "magic-string": "^0.30.21", + "pathe": "^2.0.3" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "node_modules/@vitest/spy": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/spy/-/spy-4.1.7.tgz", + "integrity": "sha512-kbkI5LMWakyuTIvs6fUJ5qdIVb1XVKsYJAT4OJ938cHMROYMSfmoQdZy0aaAnjbbc8F61vkoTqz/Az+/HiIu5Q==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://opencollective.com/vitest" + } + }, + "node_modules/@vitest/utils": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/@vitest/utils/-/utils-4.1.7.tgz", + "integrity": "sha512-T532WBu791cBxJlCl6SO+J14l81DQx6uQHm1bQbmCDY7nqlEIgkza/UFnSBNaUtSf41unldDFjdOBYEQC4b5Hw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@vitest/pretty-format": "4.1.7", + "convert-source-map": "^2.0.0", + "tinyrainbow": "^3.1.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + } + }, "node_modules/@vue/compiler-core": { "version": "3.5.34", "resolved": "https://registry.npmjs.org/@vue/compiler-core/-/compiler-core-3.5.34.tgz", @@ -1756,6 +2229,7 @@ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -1924,6 +2398,16 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/assertion-error": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-2.0.1.tgz", + "integrity": "sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + } + }, "node_modules/ast-module-types": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/ast-module-types/-/ast-module-types-7.0.0.tgz", @@ -1933,6 +2417,35 @@ "node": ">=20.19.0 || >=22.12.0" } }, + "node_modules/ast-v8-to-istanbul": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/ast-v8-to-istanbul/-/ast-v8-to-istanbul-1.0.0.tgz", + "integrity": "sha512-1fSfIwuDICFA4LKkCzRPO7F0hzFf0B7+Xqrl27ynQaa+Rh0e1Es0v6kWHPott3lU10AyAr7oKHa65OppjLn3Rg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@jridgewell/trace-mapping": "^0.3.31", + "estree-walker": "^3.0.3", + "js-tokens": "^10.0.0" + } + }, + "node_modules/ast-v8-to-istanbul/node_modules/estree-walker": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-3.0.3.tgz", + "integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/estree": "^1.0.0" + } + }, + "node_modules/ast-v8-to-istanbul/node_modules/js-tokens": { + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-10.0.0.tgz", + "integrity": "sha512-lM/UBzQmfJRo9ABXbPWemivdCW8V2G8FHaHdypQaIy523snUjog0W71ayWXTjiR+ixeMyVHN2XcpnTd/liPg/Q==", + "dev": true, + "license": "MIT" + }, "node_modules/async-function": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/async-function/-/async-function-1.0.0.tgz", @@ -2069,40 +2582,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/c8": { - "version": "11.0.0", - "resolved": "https://registry.npmjs.org/c8/-/c8-11.0.0.tgz", - "integrity": "sha512-e/uRViGHSVIJv7zsaDKM7VRn2390TgHXqUSvYwPHBQaU6L7E9L0n9JbdkwdYPvshDT0KymBmmlwSpms3yBaMNg==", - "dev": true, - "license": "ISC", - "dependencies": { - "@bcoe/v8-coverage": "^1.0.1", - "@istanbuljs/schema": "^0.1.3", - "find-up": "^5.0.0", - "foreground-child": "^3.1.1", - "istanbul-lib-coverage": "^3.2.0", - "istanbul-lib-report": "^3.0.1", - "istanbul-reports": "^3.1.6", - "test-exclude": "^8.0.0", - "v8-to-istanbul": "^9.0.0", - "yargs": "^17.7.2", - "yargs-parser": "^21.1.1" - }, - "bin": { - "c8": "bin/c8.js" - }, - "engines": { - "node": "20 || >=22" - }, - "peerDependencies": { - "monocart-coverage-reports": "^2" - }, - "peerDependenciesMeta": { - "monocart-coverage-reports": { - "optional": true - } - } - }, "node_modules/call-bind": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.9.tgz", @@ -2184,6 +2663,16 @@ ], "license": "CC-BY-4.0" }, + "node_modules/chai": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/chai/-/chai-6.2.2.tgz", + "integrity": "sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, "node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -2248,65 +2737,13 @@ "node": ">=0.8.0" } }, - "node_modules/cliui": { - "version": "8.0.1", - "resolved": "https://registry.npmjs.org/cliui/-/cliui-8.0.1.tgz", - "integrity": "sha512-BSeNnyus75C4//NQ9gQt1/csTXyo/8Sb+afLAkzAptFuMsod9HFokGNudZpi/oQV73hnVK+sR+5PVRMd+Dr7YQ==", - "dev": true, - "license": "ISC", - "dependencies": { - "string-width": "^4.2.0", - "strip-ansi": "^6.0.1", - "wrap-ansi": "^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/cliui/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/cliui/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/color-convert": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "color-name": "~1.1.4" }, @@ -2580,14 +3017,14 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/dequal": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.3.tgz", - "integrity": "sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA==", + "node_modules/detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", "dev": true, - "license": "MIT", + "license": "Apache-2.0", "engines": { - "node": ">=6" + "node": ">=8" } }, "node_modules/detective-amd": { @@ -2722,16 +3159,6 @@ "typescript": "^5.4.4 || ^6.0.2" } }, - "node_modules/diff": { - "version": "5.2.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-5.2.2.tgz", - "integrity": "sha512-vtcDfH3TOjP8UekytvnHH1o1P4FcUdt4eQ1Y+Abap1tk/OB2MWQvcwS2ClCd1zuIhc3JKOx6p3kod8Vfys3E+A==", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.3.1" - } - }, "node_modules/doctrine": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", @@ -2767,13 +3194,6 @@ "dev": true, "license": "ISC" }, - "node_modules/emoji-regex": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", - "dev": true, - "license": "MIT" - }, "node_modules/enhance-visitors": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/enhance-visitors/-/enhance-visitors-1.0.0.tgz", @@ -2976,6 +3396,13 @@ "node": ">= 0.4" } }, + "node_modules/es-module-lexer": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/es-module-lexer/-/es-module-lexer-2.1.0.tgz", + "integrity": "sha512-n27zTYMjYu1aj4MjCWzSP7G9r75utsaoc8m61weK+W8JMBGGQybd43GstCXZ3WNmSFtGT9wi59qQTW6mhTR5LQ==", + "dev": true, + "license": "MIT" + }, "node_modules/es-object-atoms": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.1.tgz", @@ -3780,6 +4207,16 @@ "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, + "node_modules/expect-type": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/expect-type/-/expect-type-1.3.0.tgz", + "integrity": "sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==", + "dev": true, + "license": "Apache-2.0", + "engines": { + "node": ">=12.0.0" + } + }, "node_modules/fast-deep-equal": { "version": "3.1.3", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", @@ -3991,21 +4428,19 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/foreground-child": { - "version": "3.3.1", - "resolved": "https://registry.npmjs.org/foreground-child/-/foreground-child-3.3.1.tgz", - "integrity": "sha512-gIXjKqtFuWEgzFRJA9WCQeSJLZDjgJUOMCMzxtvFq/37KojM1BFGufqsCy0r4qSQmYLsZYMeyRqzIWOMup03sw==", + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", "dev": true, - "license": "ISC", - "dependencies": { - "cross-spawn": "^7.0.6", - "signal-exit": "^4.0.1" - }, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], "engines": { - "node": ">=14" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, "node_modules/function-bind": { @@ -4082,16 +4517,6 @@ "node": ">=20.19.0 || >=22.12.0" } }, - "node_modules/get-caller-file": { - "version": "2.0.5", - "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", - "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", - "dev": true, - "license": "ISC", - "engines": { - "node": "6.* || 8.* || >= 10.*" - } - }, "node_modules/get-east-asian-width": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/get-east-asian-width/-/get-east-asian-width-1.6.0.tgz", @@ -4205,24 +4630,6 @@ "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" } }, - "node_modules/glob": { - "version": "13.0.6", - "resolved": "https://registry.npmjs.org/glob/-/glob-13.0.6.tgz", - "integrity": "sha512-Wjlyrolmm8uDpm/ogGyXZXb1Z+Ca2B8NbJwqBVg0axK9GbBeoS7yGV6vjXnYdGm6X53iehEuxxbyiKp8QmN4Vw==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "minimatch": "^10.2.2", - "minipass": "^7.1.3", - "path-scurry": "^2.0.2" - }, - "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/glob-parent": { "version": "6.0.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", @@ -4732,16 +5139,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", - "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/is-generator-function": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/is-generator-function/-/is-generator-function-1.1.2.tgz", @@ -5256,16 +5653,6 @@ "json-buffer": "3.0.1" } }, - "node_modules/kleur": { - "version": "4.1.5", - "resolved": "https://registry.npmjs.org/kleur/-/kleur-4.1.5.tgz", - "integrity": "sha512-o+NO+8WrRiQEE4/7nwRJhN1HWpVmJm511pBHUxPLtp0BUISzlBplORYSmTclCnJvQq2tKu/sgl3xVpkc7ZWuQQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/levn": { "version": "0.4.1", "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", @@ -5277,7 +5664,280 @@ "type-check": "~0.4.0" }, "engines": { - "node": ">= 0.8.0" + "node": ">= 0.8.0" + } + }, + "node_modules/lightningcss": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss/-/lightningcss-1.32.0.tgz", + "integrity": "sha512-NXYBzinNrblfraPGyrbPoD19C1h9lfI/1mzgWYvXUTe414Gz/X1FD2XBZSZM7rRTrMA8JL3OtAaGifrIKhQ5yQ==", + "dev": true, + "license": "MPL-2.0", + "dependencies": { + "detect-libc": "^2.0.3" + }, + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + }, + "optionalDependencies": { + "lightningcss-android-arm64": "1.32.0", + "lightningcss-darwin-arm64": "1.32.0", + "lightningcss-darwin-x64": "1.32.0", + "lightningcss-freebsd-x64": "1.32.0", + "lightningcss-linux-arm-gnueabihf": "1.32.0", + "lightningcss-linux-arm64-gnu": "1.32.0", + "lightningcss-linux-arm64-musl": "1.32.0", + "lightningcss-linux-x64-gnu": "1.32.0", + "lightningcss-linux-x64-musl": "1.32.0", + "lightningcss-win32-arm64-msvc": "1.32.0", + "lightningcss-win32-x64-msvc": "1.32.0" + } + }, + "node_modules/lightningcss-android-arm64": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-android-arm64/-/lightningcss-android-arm64-1.32.0.tgz", + "integrity": "sha512-YK7/ClTt4kAK0vo6w3X+Pnm0D2cf2vPHbhOXdoNti1Ga0al1P4TBZhwjATvjNwLEBCnKvjJc2jQgHXH0NEwlAg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-darwin-arm64": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-arm64/-/lightningcss-darwin-arm64-1.32.0.tgz", + "integrity": "sha512-RzeG9Ju5bag2Bv1/lwlVJvBE3q6TtXskdZLLCyfg5pt+HLz9BqlICO7LZM7VHNTTn/5PRhHFBSjk5lc4cmscPQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-darwin-x64": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-darwin-x64/-/lightningcss-darwin-x64-1.32.0.tgz", + "integrity": "sha512-U+QsBp2m/s2wqpUYT/6wnlagdZbtZdndSmut/NJqlCcMLTWp5muCrID+K5UJ6jqD2BFshejCYXniPDbNh73V8w==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-freebsd-x64": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-freebsd-x64/-/lightningcss-freebsd-x64-1.32.0.tgz", + "integrity": "sha512-JCTigedEksZk3tHTTthnMdVfGf61Fky8Ji2E4YjUTEQX14xiy/lTzXnu1vwiZe3bYe0q+SpsSH/CTeDXK6WHig==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm-gnueabihf": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm-gnueabihf/-/lightningcss-linux-arm-gnueabihf-1.32.0.tgz", + "integrity": "sha512-x6rnnpRa2GL0zQOkt6rts3YDPzduLpWvwAF6EMhXFVZXD4tPrBkEFqzGowzCsIWsPjqSK+tyNEODUBXeeVHSkw==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm64-gnu": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-gnu/-/lightningcss-linux-arm64-gnu-1.32.0.tgz", + "integrity": "sha512-0nnMyoyOLRJXfbMOilaSRcLH3Jw5z9HDNGfT/gwCPgaDjnx0i8w7vBzFLFR1f6CMLKF8gVbebmkUN3fa/kQJpQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-arm64-musl": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-arm64-musl/-/lightningcss-linux-arm64-musl-1.32.0.tgz", + "integrity": "sha512-UpQkoenr4UJEzgVIYpI80lDFvRmPVg6oqboNHfoH4CQIfNA+HOrZ7Mo7KZP02dC6LjghPQJeBsvXhJod/wnIBg==", + "cpu": [ + "arm64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-x64-gnu": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-gnu/-/lightningcss-linux-x64-gnu-1.32.0.tgz", + "integrity": "sha512-V7Qr52IhZmdKPVr+Vtw8o+WLsQJYCTd8loIfpDaMRWGUZfBOYEJeyJIkqGIDMZPwPx24pUMfwSxxI8phr/MbOA==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "glibc" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-linux-x64-musl": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-linux-x64-musl/-/lightningcss-linux-x64-musl-1.32.0.tgz", + "integrity": "sha512-bYcLp+Vb0awsiXg/80uCRezCYHNg1/l3mt0gzHnWV9XP1W5sKa5/TCdGWaR/zBM2PeF/HbsQv/j2URNOiVuxWg==", + "cpu": [ + "x64" + ], + "dev": true, + "libc": [ + "musl" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-win32-arm64-msvc": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-win32-arm64-msvc/-/lightningcss-win32-arm64-msvc-1.32.0.tgz", + "integrity": "sha512-8SbC8BR40pS6baCM8sbtYDSwEVQd4JlFTOlaD3gWGHfThTcABnNDBda6eTZeqbofalIJhFx0qKzgHJmcPTnGdw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" + } + }, + "node_modules/lightningcss-win32-x64-msvc": { + "version": "1.32.0", + "resolved": "https://registry.npmjs.org/lightningcss-win32-x64-msvc/-/lightningcss-win32-x64-msvc-1.32.0.tgz", + "integrity": "sha512-Amq9B/SoZYdDi1kFrojnoqPLxYhQ4Wo5XiL8EVJrVsB8ARoC1PWW6VGtT0WKCemjy8aC+louJnjS7U18x3b06Q==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, "node_modules/line-column-path": { @@ -5364,16 +6024,6 @@ "loose-envify": "cli.js" } }, - "node_modules/lru-cache": { - "version": "11.3.6", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.3.6.tgz", - "integrity": "sha512-Gf/KoL3C/MlI7Bt0PGI9I+TeTC/I6r/csU58N4BSNc4lppLBeKsOdFYkK+dX0ABDUMJNfCHTyPpzwwO21Awd3A==", - "dev": true, - "license": "BlueOak-1.0.0", - "engines": { - "node": "20 || >=22" - } - }, "node_modules/magic-string": { "version": "0.30.21", "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz", @@ -5383,6 +6033,18 @@ "@jridgewell/sourcemap-codec": "^1.5.5" } }, + "node_modules/magicast": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/magicast/-/magicast-0.5.3.tgz", + "integrity": "sha512-pVKE4UdSQ7DvHzivsCIFx2BJn1mHG6KsyrFcaxFx6tONdneEuThrDx0Cj3AMg58KyN4pzYT+LHOotxDQDjNvkw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/parser": "^7.29.3", + "@babel/types": "^7.29.0", + "source-map-js": "^1.2.1" + } + }, "node_modules/make-dir": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/make-dir/-/make-dir-4.0.0.tgz", @@ -5497,16 +6159,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/minipass": { - "version": "7.1.3", - "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.3.tgz", - "integrity": "sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A==", - "dev": true, - "license": "BlueOak-1.0.0", - "engines": { - "node": ">=16 || 14 >=14.17" - } - }, "node_modules/module-definition": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/module-definition/-/module-definition-7.0.0.tgz", @@ -5523,16 +6175,6 @@ "node": ">=20.19.0 || >=22.12.0" } }, - "node_modules/mri": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/mri/-/mri-1.2.0.tgz", - "integrity": "sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" - } - }, "node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", @@ -5779,6 +6421,17 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/obug": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/obug/-/obug-2.1.1.tgz", + "integrity": "sha512-uTqF9MuPraAQ+IsnPf366RG4cP9RtUi7MLO1N3KEc+wb0a6yKpeL0lmk2IB1jY5KHPAlTc6T/JRdC/YqxHNwkQ==", + "dev": true, + "funding": [ + "https://github.com/sponsors/sxzz", + "https://opencollective.com/debug" + ], + "license": "MIT" + }, "node_modules/open": { "version": "11.0.0", "resolved": "https://registry.npmjs.org/open/-/open-11.0.0.tgz", @@ -5959,22 +6612,12 @@ "dev": true, "license": "MIT" }, - "node_modules/path-scurry": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-2.0.2.tgz", - "integrity": "sha512-3O/iVVsJAPsOnpwWIeD+d6z/7PmqApyQePUtCndjatj/9I5LylHvt5qluFaBT3I5h3r1ejfR056c+FCv+NnNXg==", + "node_modules/pathe": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/pathe/-/pathe-2.0.3.tgz", + "integrity": "sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==", "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "lru-cache": "^11.0.0", - "minipass": "^7.1.2" - }, - "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } + "license": "MIT" }, "node_modules/picocolors": { "version": "1.1.1", @@ -6282,16 +6925,6 @@ "regjsparser": "bin/parser" } }, - "node_modules/require-directory": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/resolve": { "version": "2.0.0-next.7", "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.7.tgz", @@ -6347,6 +6980,40 @@ "node": ">=0.10.0" } }, + "node_modules/rolldown": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/rolldown/-/rolldown-1.0.2.tgz", + "integrity": "sha512-oZx5zVDtVB44AW3eaifgDml1gWRDZGvjcfdxonE4swNPG98PrrXjaO/KrnUjzlMnztCCRVlUueA1kCXhARGk6g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@oxc-project/types": "=0.132.0", + "@rolldown/pluginutils": "^1.0.0" + }, + "bin": { + "rolldown": "bin/cli.mjs" + }, + "engines": { + "node": "^20.19.0 || >=22.12.0" + }, + "optionalDependencies": { + "@rolldown/binding-android-arm64": "1.0.2", + "@rolldown/binding-darwin-arm64": "1.0.2", + "@rolldown/binding-darwin-x64": "1.0.2", + "@rolldown/binding-freebsd-x64": "1.0.2", + "@rolldown/binding-linux-arm-gnueabihf": "1.0.2", + "@rolldown/binding-linux-arm64-gnu": "1.0.2", + "@rolldown/binding-linux-arm64-musl": "1.0.2", + "@rolldown/binding-linux-ppc64-gnu": "1.0.2", + "@rolldown/binding-linux-s390x-gnu": "1.0.2", + "@rolldown/binding-linux-x64-gnu": "1.0.2", + "@rolldown/binding-linux-x64-musl": "1.0.2", + "@rolldown/binding-openharmony-arm64": "1.0.2", + "@rolldown/binding-wasm32-wasi": "1.0.2", + "@rolldown/binding-win32-arm64-msvc": "1.0.2", + "@rolldown/binding-win32-x64-msvc": "1.0.2" + } + }, "node_modules/run-applescript": { "version": "7.1.0", "resolved": "https://registry.npmjs.org/run-applescript/-/run-applescript-7.1.0.tgz", @@ -6384,19 +7051,6 @@ "queue-microtask": "^1.2.2" } }, - "node_modules/sade": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/sade/-/sade-1.8.1.tgz", - "integrity": "sha512-xal3CZX1Xlo/k4ApwCFrHVACi9fBqJ7V+mwhBsuf/1IOKbBy098Fex+Wa/5QMubw09pSZ/u8EY8PWgevJsXp1A==", - "dev": true, - "license": "MIT", - "dependencies": { - "mri": "^1.1.0" - }, - "engines": { - "node": ">=6" - } - }, "node_modules/safe-array-concat": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.1.4.tgz", @@ -6612,6 +7266,13 @@ "url": "https://github.com/sponsors/ljharb" } }, + "node_modules/siginfo": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/siginfo/-/siginfo-2.0.0.tgz", + "integrity": "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==", + "dev": true, + "license": "ISC" + }, "node_modules/signal-exit": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", @@ -6667,6 +7328,20 @@ "node": ">=12.0.0" } }, + "node_modules/stackback": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/stackback/-/stackback-0.0.2.tgz", + "integrity": "sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==", + "dev": true, + "license": "MIT" + }, + "node_modules/std-env": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/std-env/-/std-env-4.1.0.tgz", + "integrity": "sha512-Rq7ybcX2RuC55r9oaPVEW7/xu3tj8u4GeBYHBWCychFtzMIr86A7e3PPEBPT37sHStKX3+TiX/Fr/ACmJLVlLQ==", + "dev": true, + "license": "MIT" + }, "node_modules/stop-iteration-iterator": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.1.0.tgz", @@ -6964,19 +7639,21 @@ "url": "https://opencollective.com/webpack" } }, - "node_modules/test-exclude": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/test-exclude/-/test-exclude-8.0.0.tgz", - "integrity": "sha512-ZOffsNrXYggvU1mDGHk54I96r26P8SyMjO5slMKSc7+IWmtB/MQKnEC2fP51imB3/pT6YK5cT5E8f+Dd9KdyOQ==", + "node_modules/tinybench": { + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/tinybench/-/tinybench-2.9.0.tgz", + "integrity": "sha512-0+DUvqWMValLmha6lr4kD8iAMK1HzV0/aKnCtWb9v9641TnP/MFb7Pc2bxoxQjTXAErryXVgUOfv2YqNllqGeg==", "dev": true, - "license": "ISC", - "dependencies": { - "@istanbuljs/schema": "^0.1.2", - "glob": "^13.0.6", - "minimatch": "^10.2.2" - }, + "license": "MIT" + }, + "node_modules/tinyexec": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.1.2.tgz", + "integrity": "sha512-dAqSqE/RabpBKI8+h26GfLq6Vb3JVXs30XYQjdMjaj/c2tS8IYYMbIzP599KtRj7c57/wYApb3QjgRgXmrCukA==", + "dev": true, + "license": "MIT", "engines": { - "node": "20 || >=22" + "node": ">=18" } }, "node_modules/tinyglobby": { @@ -6995,6 +7672,16 @@ "url": "https://github.com/sponsors/SuperchupuDev" } }, + "node_modules/tinyrainbow": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/tinyrainbow/-/tinyrainbow-3.1.0.tgz", + "integrity": "sha512-Bf+ILmBgretUrdJxzXM0SgXLZ3XfiaUuOj/IKQHuTXip+05Xn+uyEYdVg0kYDipTBcLrCVyUzAPz7QmArb0mmw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14.0.0" + } + }, "node_modules/to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", @@ -7303,38 +7990,172 @@ "punycode": "^2.1.0" } }, - "node_modules/uvu": { - "version": "0.5.6", - "resolved": "https://registry.npmjs.org/uvu/-/uvu-0.5.6.tgz", - "integrity": "sha512-+g8ENReyr8YsOc6fv/NVJs2vFdHBnBNdfE49rshrTzDWOlUx4Gq7KOS2GD8eqhy2j+Ejq29+SbKH8yjkAqXqoA==", + "node_modules/vite": { + "version": "8.0.14", + "resolved": "https://registry.npmjs.org/vite/-/vite-8.0.14.tgz", + "integrity": "sha512-s4BJJ+5y1pYL6Otw51FHhVJQhPnuRinKig64g/1+EUNaJsd3gCKdD31IPFvswUgW9/60QT9oFHbZHbQK5imcxw==", "dev": true, "license": "MIT", "dependencies": { - "dequal": "^2.0.0", - "diff": "^5.0.0", - "kleur": "^4.0.3", - "sade": "^1.7.3" + "lightningcss": "^1.32.0", + "picomatch": "^4.0.4", + "postcss": "^8.5.15", + "rolldown": "1.0.2", + "tinyglobby": "^0.2.16" }, "bin": { - "uvu": "bin.js" + "vite": "bin/vite.js" }, "engines": { - "node": ">=8" + "node": "^20.19.0 || >=22.12.0" + }, + "funding": { + "url": "https://github.com/vitejs/vite?sponsor=1" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + }, + "peerDependencies": { + "@types/node": "^20.19.0 || >=22.12.0", + "@vitejs/devtools": "^0.1.18", + "esbuild": "^0.27.0 || ^0.28.0", + "jiti": ">=1.21.0", + "less": "^4.0.0", + "sass": "^1.70.0", + "sass-embedded": "^1.70.0", + "stylus": ">=0.54.8", + "sugarss": "^5.0.0", + "terser": "^5.16.0", + "tsx": "^4.8.1", + "yaml": "^2.4.2" + }, + "peerDependenciesMeta": { + "@types/node": { + "optional": true + }, + "@vitejs/devtools": { + "optional": true + }, + "esbuild": { + "optional": true + }, + "jiti": { + "optional": true + }, + "less": { + "optional": true + }, + "sass": { + "optional": true + }, + "sass-embedded": { + "optional": true + }, + "stylus": { + "optional": true + }, + "sugarss": { + "optional": true + }, + "terser": { + "optional": true + }, + "tsx": { + "optional": true + }, + "yaml": { + "optional": true + } } }, - "node_modules/v8-to-istanbul": { - "version": "9.3.0", - "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-9.3.0.tgz", - "integrity": "sha512-kiGUalWN+rgBJ/1OHZsBtU4rXZOfj/7rKQxULKlIzwzQSvMJUUNgPwJEEh7gU6xEVxC0ahoOBvN2YI8GH6FNgA==", + "node_modules/vitest": { + "version": "4.1.7", + "resolved": "https://registry.npmjs.org/vitest/-/vitest-4.1.7.tgz", + "integrity": "sha512-flYyaFd2CgoCoU+0UKt3pxksgC+S02iTDN0n3LtqaMeXsI9SBcdNujc2k0DeFLzUn/0k538yNjOSdwgCqcrwJA==", "dev": true, - "license": "ISC", + "license": "MIT", "dependencies": { - "@jridgewell/trace-mapping": "^0.3.12", - "@types/istanbul-lib-coverage": "^2.0.1", - "convert-source-map": "^2.0.0" + "@vitest/expect": "4.1.7", + "@vitest/mocker": "4.1.7", + "@vitest/pretty-format": "4.1.7", + "@vitest/runner": "4.1.7", + "@vitest/snapshot": "4.1.7", + "@vitest/spy": "4.1.7", + "@vitest/utils": "4.1.7", + "es-module-lexer": "^2.0.0", + "expect-type": "^1.3.0", + "magic-string": "^0.30.21", + "obug": "^2.1.1", + "pathe": "^2.0.3", + "picomatch": "^4.0.3", + "std-env": "^4.0.0-rc.1", + "tinybench": "^2.9.0", + "tinyexec": "^1.0.2", + "tinyglobby": "^0.2.15", + "tinyrainbow": "^3.1.0", + "vite": "^6.0.0 || ^7.0.0 || ^8.0.0", + "why-is-node-running": "^2.3.0" + }, + "bin": { + "vitest": "vitest.mjs" }, "engines": { - "node": ">=10.12.0" + "node": "^20.0.0 || ^22.0.0 || >=24.0.0" + }, + "funding": { + "url": "https://opencollective.com/vitest" + }, + "peerDependencies": { + "@edge-runtime/vm": "*", + "@opentelemetry/api": "^1.9.0", + "@types/node": "^20.0.0 || ^22.0.0 || >=24.0.0", + "@vitest/browser-playwright": "4.1.7", + "@vitest/browser-preview": "4.1.7", + "@vitest/browser-webdriverio": "4.1.7", + "@vitest/coverage-istanbul": "4.1.7", + "@vitest/coverage-v8": "4.1.7", + "@vitest/ui": "4.1.7", + "happy-dom": "*", + "jsdom": "*", + "vite": "^6.0.0 || ^7.0.0 || ^8.0.0" + }, + "peerDependenciesMeta": { + "@edge-runtime/vm": { + "optional": true + }, + "@opentelemetry/api": { + "optional": true + }, + "@types/node": { + "optional": true + }, + "@vitest/browser-playwright": { + "optional": true + }, + "@vitest/browser-preview": { + "optional": true + }, + "@vitest/browser-webdriverio": { + "optional": true + }, + "@vitest/coverage-istanbul": { + "optional": true + }, + "@vitest/coverage-v8": { + "optional": true + }, + "@vitest/ui": { + "optional": true + }, + "happy-dom": { + "optional": true + }, + "jsdom": { + "optional": true + }, + "vite": { + "optional": false + } } }, "node_modules/which": { @@ -7442,70 +8263,31 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/word-wrap": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", - "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, - "node_modules/wrap-ansi": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", - "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", + "node_modules/why-is-node-running": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/why-is-node-running/-/why-is-node-running-2.3.0.tgz", + "integrity": "sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==", "dev": true, "license": "MIT", "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" + "siginfo": "^2.0.0", + "stackback": "0.0.2" }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/wrap-ansi/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" + "bin": { + "why-is-node-running": "cli.js" }, "engines": { "node": ">=8" } }, - "node_modules/wrap-ansi/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "node_modules/word-wrap": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", + "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", "dev": true, "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, "engines": { - "node": ">=8" + "node": ">=0.10.0" } }, "node_modules/wsl-utils": { @@ -7810,16 +8592,6 @@ "node": ">=14.17" } }, - "node_modules/y18n": { - "version": "5.0.8", - "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", - "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=10" - } - }, "node_modules/yallist": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", @@ -7827,73 +8599,6 @@ "dev": true, "license": "ISC" }, - "node_modules/yargs": { - "version": "17.7.2", - "resolved": "https://registry.npmjs.org/yargs/-/yargs-17.7.2.tgz", - "integrity": "sha512-7dSzzRQ++CKnNI/krKnYRV7JKKPUXMEh61soaHKg9mrWEhzFWhFnxPxGl+69cD1Ou63C13NUPCnmIcrvqCuM6w==", - "dev": true, - "license": "MIT", - "dependencies": { - "cliui": "^8.0.1", - "escalade": "^3.1.1", - "get-caller-file": "^2.0.5", - "require-directory": "^2.1.1", - "string-width": "^4.2.3", - "y18n": "^5.0.5", - "yargs-parser": "^21.1.1" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs-parser": { - "version": "21.1.1", - "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", - "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", - "dev": true, - "license": "ISC", - "engines": { - "node": ">=12" - } - }, - "node_modules/yargs/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, - "license": "MIT", - "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=8" - } - }, - "node_modules/yargs/node_modules/strip-ansi": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", - "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-regex": "^5.0.1" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/yocto-queue": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", diff --git a/package.json b/package.json index d57b7f9..7cdfa72 100644 --- a/package.json +++ b/package.json @@ -14,9 +14,9 @@ "check:types": "npm run generate:types && git diff HEAD --exit-code index.d.ts", "lint": "xo", "fix": "xo --fix", - "uvu": "uvu test \".test.js\" -i fixtures", - "test": "npm run lint && npm run check:types && npm run uvu", - "test:ci": "c8 npm run uvu" + "vitest": "vitest run", + "test": "npm run lint && npm run vitest", + "test:ci": "npm run vitest -- --coverage" }, "bin": { "precinct": "bin/cli.js" @@ -69,8 +69,8 @@ }, "devDependencies": { "@babel/parser": "^7.29.3", - "c8": "^11.0.0", - "uvu": "^0.5.6", + "@vitest/coverage-v8": "^4.1.7", + "vitest": "^4.1.7", "xo": "^2.0.2" } } diff --git a/test/amd.test.js b/test/amd.test.js index 7446fee..265e284 100644 --- a/test/amd.test.js +++ b/test/amd.test.js @@ -1,16 +1,13 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { readFixture } from './helpers.js'; -const test = suite('AMD'); - -test('grabs dependencies', async() => { - const fixture = await readFixture('amd.js'); - const result = precinct(fixture); - assert.equal(result.includes('./a'), true); - assert.equal(result.includes('./b'), true); - assert.equal(result.length, 2); +describe('AMD', () => { + it('grabs dependencies', async() => { + const fixture = await readFixture('amd.js'); + const result = precinct(fixture); + expect(result.includes('./a')).toBe(true); + expect(result.includes('./b')).toBe(true); + expect(result.length).toBe(2); + }); }); - -test.run(); diff --git a/test/ast.test.js b/test/ast.test.js index b032bbc..2a5dd32 100644 --- a/test/ast.test.js +++ b/test/ast.test.js @@ -1,37 +1,34 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import ast from './fixtures/exampleAST.js'; import { readFixture } from './helpers.js'; -const test = suite('AST'); +describe('AST', () => { + it('accepts an AST', () => { + const deps = precinct(ast); + expect(deps.length).toBe(1); + }); -test('accepts an AST', () => { - const deps = precinct(ast); - assert.equal(deps.length, 1); -}); - -test('dangles off a given ast', () => { - assert.deepEqual(precinct.ast, ast); -}); + it('dangles off a given ast', () => { + expect(precinct.ast).toStrictEqual(ast); + }); -test('dangles off the parsed ast from a .js file', async() => { - const fixture = await readFixture('amd.js'); - precinct(fixture); - assert.notEqual(precinct.ast, null); - assert.notDeepEqual(precinct.ast, ast); -}); + it('dangles off the parsed ast from a .js file', async() => { + const fixture = await readFixture('amd.js'); + precinct(fixture); + expect(precinct.ast).not.toBe(null); + expect(precinct.ast).not.toStrictEqual(ast); + }); -test('dangles off the parsed ast from a scss detective', async() => { - const fixture = await readFixture('styles.scss'); - precinct(fixture, { type: 'scss' }); - assert.notDeepEqual(precinct.ast, {}); -}); + it('dangles off the parsed ast from a scss detective', async() => { + const fixture = await readFixture('styles.scss'); + precinct(fixture, { type: 'scss' }); + expect(precinct.ast).not.toStrictEqual({}); + }); -test('dangles off the parsed ast from a sass detective', async() => { - const fixture = await readFixture('styles.sass'); - precinct(fixture, { type: 'sass' }); - assert.notDeepEqual(precinct.ast, {}); + it('dangles off the parsed ast from a sass detective', async() => { + const fixture = await readFixture('styles.sass'); + precinct(fixture, { type: 'sass' }); + expect(precinct.ast).not.toStrictEqual({}); + }); }); - -test.run(); diff --git a/test/commonjs.test.js b/test/commonjs.test.js index abfb7c4..7cc08a2 100644 --- a/test/commonjs.test.js +++ b/test/commonjs.test.js @@ -1,60 +1,57 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { readFixture } from './helpers.js'; -const test = suite('CommonJS'); - -test('grabs dependencies', async() => { - const fixture = await readFixture('commonjs.js'); - const result = precinct(fixture); - assert.equal(result.includes('./a'), true); - assert.equal(result.includes('./b'), true); - assert.equal(result.length, 2); - assert.deepEqual(precinct(fixture, { type: 'cjs' }), result); -}); +describe('CommonJS', () => { + it('grabs dependencies', async() => { + const fixture = await readFixture('commonjs.js'); + const result = precinct(fixture); + expect(result.includes('./a')).toBe(true); + expect(result.includes('./b')).toBe(true); + expect(result.length).toBe(2); + expect(precinct(fixture, { type: 'cjs' })).toStrictEqual(result); + }); -test('grabs lazy exported dependencies', async() => { - const fixture = await readFixture('cjsExportLazy.js'); - const result = precinct(fixture); - assert.equal(result[0], './amd'); - assert.equal(result[1], './es6'); - assert.equal(result[2], './es7'); - assert.equal(result.length, 3); -}); + it('grabs lazy exported dependencies', async() => { + const fixture = await readFixture('cjsExportLazy.js'); + const result = precinct(fixture); + expect(result[0]).toBe('./amd'); + expect(result[1]).toBe('./es6'); + expect(result[2]).toBe('./es7'); + expect(result.length).toBe(3); + }); -test('grabs dependencies when a main require is used', async() => { - const fixture = await readFixture('commonjs-requiremain.js'); - const result = precinct(fixture); - assert.equal(result[0], './b'); - assert.equal(result.length, 1); -}); + it('grabs dependencies when a main require is used', async() => { + const fixture = await readFixture('commonjs-requiremain.js'); + const result = precinct(fixture); + expect(result[0]).toBe('./b'); + expect(result.length).toBe(1); + }); -test('yields no dependencies for non-modules', async() => { - const fixture = await readFixture('none.js'); - const result = precinct(fixture); - assert.equal(result.length, 0); -}); + it('yields no dependencies for non-modules', async() => { + const fixture = await readFixture('none.js'); + const result = precinct(fixture); + expect(result.length).toBe(0); + }); -test('ignores unparsable .js files', async() => { - const fixture = await readFixture('unparseable.js'); - const result = precinct(fixture); - assert.equal(result.includes('lib'), false); - assert.equal(result.length, 0); -}); + it('ignores unparsable .js files', async() => { + const fixture = await readFixture('unparseable.js'); + const result = precinct(fixture); + expect(result.includes('lib')).toBe(false); + expect(result.length).toBe(0); + }); -test('does not throw on unparsable .js files', async() => { - const fixture = await readFixture('unparseable.js'); - assert.doesNotThrow(() => { - precinct(fixture); - }, SyntaxError); -}); + it('does not throw on unparsable .js files', async() => { + const fixture = await readFixture('unparseable.js'); + expect(() => { + precinct(fixture); + }).not.toThrow(); + }); -test('does not blow up when parsing a gruntfile #2', async() => { - const fixture = await readFixture('Gruntfile.js'); - assert.doesNotThrow(() => { - precinct(fixture); + it('does not blow up when parsing a gruntfile #2', async() => { + const fixture = await readFixture('Gruntfile.js'); + expect(() => { + precinct(fixture); + }).not.toThrow(); }); }); - -test.run(); diff --git a/test/configuration.test.js b/test/configuration.test.js index 3f6fbb2..3023c2b 100644 --- a/test/configuration.test.js +++ b/test/configuration.test.js @@ -1,81 +1,78 @@ -import { strict as assert } from 'node:assert'; +import { describe, it, expect } from 'vitest'; import parser from '@babel/parser'; -import { suite } from 'uvu'; import precinct from '../index.js'; import { fixturePath, readFixture } from './helpers.js'; -const test = suite('configuration'); - -test('passes amd config to the amd detective', async() => { - const fixture = await readFixture('amdLazy.js'); - const withLazy = precinct(fixture); - const withoutLazy = precinct(fixture, { - amd: { - skipLazyLoaded: true - } +describe('configuration', () => { + it('passes amd config to the amd detective', async() => { + const fixture = await readFixture('amdLazy.js'); + const withLazy = precinct(fixture); + const withoutLazy = precinct(fixture, { + amd: { + skipLazyLoaded: true + } + }); + expect(withLazy.includes('./b')).toBe(true); + expect(withoutLazy.includes('./b')).toBe(false); }); - assert.equal(withLazy.includes('./b'), true); - assert.equal(withoutLazy.includes('./b'), false); -}); -test('supports the object form of type configuration', async() => { - const fixture = await readFixture('styles.styl'); - const result = precinct(fixture, { type: 'stylus' }); - const expected = ['mystyles', 'styles2.styl', 'styles3.styl', 'styles4']; - assert.deepEqual(result, expected); -}); + it('supports the object form of type configuration', async() => { + const fixture = await readFixture('styles.styl'); + const result = precinct(fixture, { type: 'stylus' }); + const expected = ['mystyles', 'styles2.styl', 'styles3.styl', 'styles4']; + expect(result).toStrictEqual(expected); + }); -test('walker options: finds imports inside blocks when allowImportExportEverywhere is enabled', async() => { - const fixture = await readFixture('es6ImportInsideBlock.js'); - const withoutOption = precinct(fixture); - assert.equal(withoutOption.length, 0); + it('walker options: finds imports inside blocks when allowImportExportEverywhere is enabled', async() => { + const fixture = await readFixture('es6ImportInsideBlock.js'); + const withoutOption = precinct(fixture); + expect(withoutOption.length).toBe(0); - const withOption = precinct(fixture, { - walker: { - allowImportExportEverywhere: true - } + const withOption = precinct(fixture, { + walker: { + allowImportExportEverywhere: true + } + }); + expect(withOption.includes('lib')).toBe(true); + expect(withOption.length).toBe(1); }); - assert.equal(withOption.includes('lib'), true); - assert.equal(withOption.length, 1); -}); -test('walker options: accepts a custom parser via walker options', async() => { - const fixture = await readFixture('commonjs.js'); + it('walker options: accepts a custom parser via walker options', async() => { + const fixture = await readFixture('commonjs.js'); - const prebuiltAst = parser.parse(fixture, { - sourceType: 'module', - allowHashBang: true - }); + const prebuiltAst = parser.parse(fixture, { + sourceType: 'module', + allowHashBang: true + }); - let parseCallCount = 0; - const customParser = { - parse() { - parseCallCount++; - return prebuiltAst; - } - }; + let parseCallCount = 0; + const customParser = { + parse() { + parseCallCount++; + return prebuiltAst; + } + }; - const result = precinct(fixture, { - walker: { - parser: customParser - } + const result = precinct(fixture, { + walker: { + parser: customParser + } + }); + expect(parseCallCount).toBe(1); + expect(result.includes('./a')).toBe(true); }); - assert.equal(parseCallCount, 1); - assert.equal(result.includes('./a'), true); -}); -test('walker options: passes walker options through paperwork', () => { - const fixture = fixturePath('es6ImportInsideBlock.js'); - const withoutOption = precinct.paperwork(fixture); - assert.equal(withoutOption.length, 0); + it('walker options: passes walker options through paperwork', () => { + const fixture = fixturePath('es6ImportInsideBlock.js'); + const withoutOption = precinct.paperwork(fixture); + expect(withoutOption.length).toBe(0); - const withOption = precinct.paperwork(fixture, { - walker: { - allowImportExportEverywhere: true - } + const withOption = precinct.paperwork(fixture, { + walker: { + allowImportExportEverywhere: true + } + }); + expect(withOption.includes('lib')).toBe(true); + expect(withOption.length).toBe(1); }); - assert.equal(withOption.includes('lib'), true); - assert.equal(withOption.length, 1); }); - -test.run(); diff --git a/test/es6.test.js b/test/es6.test.js index d60c476..547dbf6 100644 --- a/test/es6.test.js +++ b/test/es6.test.js @@ -1,126 +1,123 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { fixturePath, readFixture } from './helpers.js'; -const test = suite('ES6'); - -test('grabs dependencies', async() => { - const fixture = await readFixture('es6.js'); - const result = precinct(fixture); - assert.equal(result.includes('lib'), true); - assert.equal(result.length, 1); -}); +describe('ES6', () => { + it('grabs dependencies', async() => { + const fixture = await readFixture('es6.js'); + const result = precinct(fixture); + expect(result.includes('lib')).toBe(true); + expect(result.length).toBe(1); + }); -test('grabs dependencies with embedded jsx', async() => { - const fixture = await readFixture('jsx.js'); - const result = precinct(fixture); - assert.equal(result.includes('lib'), true); - assert.equal(result.length, 1); -}); + it('grabs dependencies with embedded jsx', async() => { + const fixture = await readFixture('jsx.js'); + const result = precinct(fixture); + expect(result.includes('lib')).toBe(true); + expect(result.length).toBe(1); + }); -test('grabs dependencies with embedded es7', async() => { - const fixture = await readFixture('es7.js'); - const result = precinct(fixture); - assert.equal(result.includes('lib'), true); - assert.equal(result.length, 1); -}); + it('grabs dependencies with embedded es7', async() => { + const fixture = await readFixture('es7.js'); + const result = precinct(fixture); + expect(result.includes('lib')).toBe(true); + expect(result.length).toBe(1); + }); -test('handles the esm extension', () => { - const fixture = fixturePath('es6.esm'); - const result = precinct.paperwork(fixture); - assert.equal(result.includes('lib'), true); - assert.equal(result.length, 1); -}); + it('handles the esm extension', () => { + const fixture = fixturePath('es6.esm'); + const result = precinct.paperwork(fixture); + expect(result.includes('lib')).toBe(true); + expect(result.length).toBe(1); + }); -test('handles the mjs extension', () => { - const fixture = fixturePath('es6.mjs'); - const result = precinct.paperwork(fixture); - assert.equal(result.includes('lib'), true); - assert.equal(result.length, 1); -}); + it('handles the mjs extension', () => { + const fixture = fixturePath('es6.mjs'); + const result = precinct.paperwork(fixture); + expect(result.includes('lib')).toBe(true); + expect(result.length).toBe(1); + }); -test('yields no dependencies when there are no imports', async() => { - const fixture = await readFixture('es6NoImport.js'); - const result = precinct(fixture); - assert.equal(result.length, 0); -}); + it('yields no dependencies when there are no imports', async() => { + const fixture = await readFixture('es6NoImport.js'); + const result = precinct(fixture); + expect(result.length).toBe(0); + }); -test('does not grab dependencies when there are syntax errors', async() => { - const fixture = await readFixture('es6WithError.js'); - const result = precinct(fixture); - assert.equal(result.length, 0); -}); + it('does not grab dependencies when there are syntax errors', async() => { + const fixture = await readFixture('es6WithError.js'); + const result = precinct(fixture); + expect(result.length).toBe(0); + }); -test('grabs dynamic imports', async() => { - const fixture = await readFixture('es6DynamicImport.js'); - const result = precinct(fixture); - assert.equal(result[0], './bar'); -}); + it('grabs dynamic imports', async() => { + const fixture = await readFixture('es6DynamicImport.js'); + const result = precinct(fixture); + expect(result[0]).toBe('./bar'); + }); -test('mixed imports: returns both commonjs and es6 dependencies for es6 files', async() => { - const fixture = await readFixture('es6MixedImport.js'); - const result = precinct(fixture, { - es6: { - mixedImports: true - } + it('mixed imports: returns both commonjs and es6 dependencies for es6 files', async() => { + const fixture = await readFixture('es6MixedImport.js'); + const result = precinct(fixture, { + es6: { + mixedImports: true + } + }); + expect(result.length).toBe(2); }); - assert.equal(result.length, 2); -}); -test('mixed imports: returns both commonjs and es6 dependencies for cjs files', async() => { - const fixture = await readFixture('cjsMixedImport.js'); - const result = precinct(fixture, { - es6: { - mixedImports: true - } + it('mixed imports: returns both commonjs and es6 dependencies for cjs files', async() => { + const fixture = await readFixture('cjsMixedImport.js'); + const result = precinct(fixture, { + es6: { + mixedImports: true + } + }); + expect(result.length).toBe(2); }); - assert.equal(result.length, 2); -}); -test('mixed imports: grabs lazy cjs exports when mixedImports is enabled', async() => { - const fixture = await readFixture('es6MixedExportLazy.js'); - const result = precinct(fixture, { - es6: { - mixedImports: true - } - }); - assert.equal(result[0], './amd'); - assert.equal(result[1], './es6'); - assert.equal(result[2], './es7'); - assert.equal(result.length, 3); -}); + it('mixed imports: grabs lazy cjs exports when mixedImports is enabled', async() => { + const fixture = await readFixture('es6MixedExportLazy.js'); + const result = precinct(fixture, { + es6: { + mixedImports: true + } + }); + expect(result[0]).toBe('./amd'); + expect(result[1]).toBe('./es6'); + expect(result[2]).toBe('./es7'); + expect(result.length).toBe(3); + }); -test('mixed imports: does not grab lazy cjs exports when mixedImports is disabled', async() => { - const fixture = await readFixture('es6MixedExportLazy.js'); - const result = precinct(fixture); - assert.equal(result.length, 0); -}); + it('mixed imports: does not grab lazy cjs exports when mixedImports is disabled', async() => { + const fixture = await readFixture('es6MixedExportLazy.js'); + const result = precinct(fixture); + expect(result.length).toBe(0); + }); -test('node: prefix: assumes node:-prefixed builtins exist', () => { - const fixture = fixturePath('internalNodePrefix.js'); - const result = precinct.paperwork(fixture, { includeCore: false }); - assert.equal(result.includes('node:nonexistant'), false); - assert.deepEqual(result, ['streams']); -}); + it('node: prefix: assumes node:-prefixed builtins exist', () => { + const fixture = fixturePath('internalNodePrefix.js'); + const result = precinct.paperwork(fixture, { includeCore: false }); + expect(result.includes('node:nonexistant')).toBe(false); + expect(result).toStrictEqual(['streams']); + }); -test('node: prefix: does not filter out node:-prefixed builtins by default', () => { - const fixture = fixturePath('nodeBuiltinPrefix.js'); - const result = precinct.paperwork(fixture); - assert.equal(result.includes('node:fs'), true); - assert.equal(result.includes('node:path'), true); -}); + it('node: prefix: does not filter out node:-prefixed builtins by default', () => { + const fixture = fixturePath('nodeBuiltinPrefix.js'); + const result = precinct.paperwork(fixture); + expect(result.includes('node:fs')).toBe(true); + expect(result.includes('node:path')).toBe(true); + }); -test('node: prefix: understands quirks around modules only addressable via node: prefix', () => { - const fixture = fixturePath('requiretest.js'); - const result = precinct.paperwork(fixture, { includeCore: false }); - assert.deepEqual(result, ['test']); -}); + it('node: prefix: understands quirks around modules only addressable via node: prefix', () => { + const fixture = fixturePath('requiretest.js'); + const result = precinct.paperwork(fixture, { includeCore: false }); + expect(result).toStrictEqual(['test']); + }); -test('node: prefix: filters out node:-prefixed builtins when includeCore is false', () => { - const fixture = fixturePath('nodeBuiltinPrefix.js'); - const result = precinct.paperwork(fixture, { includeCore: false }); - assert.deepEqual(result, ['./myModule']); + it('node: prefix: filters out node:-prefixed builtins when includeCore is false', () => { + const fixture = fixturePath('nodeBuiltinPrefix.js'); + const result = precinct.paperwork(fixture, { includeCore: false }); + expect(result).toStrictEqual(['./myModule']); + }); }); - -test.run(); diff --git a/test/paperwork.test.js b/test/paperwork.test.js index 421fc9e..2fe37a1 100644 --- a/test/paperwork.test.js +++ b/test/paperwork.test.js @@ -1,85 +1,82 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { fixturePath } from './helpers.js'; -const test = suite('paperwork'); +describe('paperwork', () => { + it('grabs dependencies of jsx files', () => { + const fixture = fixturePath('module.jsx'); + const result = precinct.paperwork(fixture); + const expected = ['./es6NoImport']; + expect(result).toStrictEqual(expected); + }); -test('grabs dependencies of jsx files', () => { - const fixture = fixturePath('module.jsx'); - const result = precinct.paperwork(fixture); - const expected = ['./es6NoImport']; - assert.deepEqual(result, expected); -}); + it('uses fileSystem from options if provided', () => { + const fsMock = { + readFileSync(filePath) { + expect(filePath).toBe('/foo.js'); + return 'var assert = require("assert");'; + } + }; -test('uses fileSystem from options if provided', () => { - const fsMock = { - readFileSync(filePath) { - assert.equal(filePath, '/foo.js'); - return 'var assert = require("assert");'; - } - }; - - const fixture = '/foo.js'; - const results = precinct.paperwork(fixture, { fileSystem: fsMock }); - assert.equal(results.length, 1); - assert.equal(results[0], 'assert'); -}); + const fixture = '/foo.js'; + const results = precinct.paperwork(fixture, { fileSystem: fsMock }); + expect(results.length).toBe(1); + expect(results[0]).toBe('assert'); + }); -test('returns the dependencies for the given filepath', () => { - const fixtures = ['es6.js', 'styles.scss', 'typescript.ts', 'styles.css']; + it('returns the dependencies for the given filepath', () => { + const fixtures = ['es6.js', 'styles.scss', 'typescript.ts', 'styles.css']; - for (const fixture of fixtures) { - const result = precinct.paperwork(fixturePath(fixture)); - assert.notEqual(result.length, 0); - } -}); + for (const fixture of fixtures) { + const result = precinct.paperwork(fixturePath(fixture)); + expect(result.length).not.toBe(0); + } + }); -test('throws if the file cannot be found', () => { - assert.throws(() => { - precinct.paperwork('foo'); + it('throws if the file cannot be found', () => { + expect(() => { + precinct.paperwork('foo'); + }).toThrow(); }); -}); -test('filters out core modules if options.includeCore is false', () => { - const fixture = fixturePath('coreModules.js'); - const result = precinct.paperwork(fixture, { includeCore: false }); - assert.equal(result.length, 0); -}); + it('filters out core modules if options.includeCore is false', () => { + const fixture = fixturePath('coreModules.js'); + const result = precinct.paperwork(fixture, { includeCore: false }); + expect(result.length).toBe(0); + }); -test('does not filter out core modules by default', () => { - const fixture = fixturePath('coreModules.js'); - const result = precinct.paperwork(fixture); - assert.notEqual(result.length, 0); -}); + it('does not filter out core modules by default', () => { + const fixture = fixturePath('coreModules.js'); + const result = precinct.paperwork(fixture); + expect(result.length).not.toBe(0); + }); -test('handles cjs files as commonjs', () => { - const fixture = fixturePath('commonjs.cjs'); - const result = precinct.paperwork(fixture); - assert.equal(result.includes('./a'), true); - assert.equal(result.includes('./b'), true); -}); + it('handles cjs files as commonjs', () => { + const fixture = fixturePath('commonjs.cjs'); + const result = precinct.paperwork(fixture); + expect(result.includes('./a')).toBe(true); + expect(result.includes('./b')).toBe(true); + }); -test('passes detective configuration to the underlying detective', () => { - const fixture = fixturePath('amdLazy.js'); - const withLazy = precinct.paperwork(fixture); - const withoutLazy = precinct.paperwork(fixture, { - amd: { - skipLazyLoaded: true - } + it('passes detective configuration to the underlying detective', () => { + const fixture = fixturePath('amdLazy.js'); + const withLazy = precinct.paperwork(fixture); + const withoutLazy = precinct.paperwork(fixture, { + amd: { + skipLazyLoaded: true + } + }); + expect(withLazy.includes('./b')).toBe(true); + expect(withoutLazy.includes('./b')).toBe(false); }); - assert.equal(withLazy.includes('./b'), true); - assert.equal(withoutLazy.includes('./b'), false); -}); -test('does not filter out core modules by default when given detective configuration', () => { - const fixture = fixturePath('coreModules.js'); - const result = precinct.paperwork(fixture, { - amd: { - skipLazyLoaded: true - } + it('does not filter out core modules by default when given detective configuration', () => { + const fixture = fixturePath('coreModules.js'); + const result = precinct.paperwork(fixture, { + amd: { + skipLazyLoaded: true + } + }); + expect(result.length).not.toBe(0); }); - assert.notEqual(result.length, 0); }); - -test.run(); diff --git a/test/stylesheets.test.js b/test/stylesheets.test.js index b894fea..d165ce3 100644 --- a/test/stylesheets.test.js +++ b/test/stylesheets.test.js @@ -1,40 +1,37 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { fixturePath, readFixture } from './helpers.js'; -const test = suite('stylesheets'); +describe('stylesheets', () => { + it('grabs dependencies of css files', async() => { + const fixture = await readFixture('styles.css'); + const result = precinct(fixture, { type: 'css' }); + expect(result).toStrictEqual(['foo.css', 'baz.css', 'bla.css', 'another.css']); + }); -test('grabs dependencies of css files', async() => { - const fixture = await readFixture('styles.css'); - const result = precinct(fixture, { type: 'css' }); - assert.deepEqual(result, ['foo.css', 'baz.css', 'bla.css', 'another.css']); -}); - -test('grabs dependencies of scss files', async() => { - const fixture = await readFixture('styles.scss'); - const result = precinct(fixture, { type: 'scss' }); - assert.deepEqual(result, ['_foo', 'baz.scss']); -}); + it('grabs dependencies of scss files', async() => { + const fixture = await readFixture('styles.scss'); + const result = precinct(fixture, { type: 'scss' }); + expect(result).toStrictEqual(['_foo', 'baz.scss']); + }); -test('grabs dependencies of sass files', async() => { - const fixture = await readFixture('styles.sass'); - const result = precinct(fixture, { type: 'sass' }); - assert.deepEqual(result, ['_foo']); -}); + it('grabs dependencies of sass files', async() => { + const fixture = await readFixture('styles.sass'); + const result = precinct(fixture, { type: 'sass' }); + expect(result).toStrictEqual(['_foo']); + }); -test('grabs dependencies of stylus files', () => { - const fixture = fixturePath('styles.styl'); - const result = precinct.paperwork(fixture); - const expected = ['mystyles', 'styles2.styl', 'styles3.styl', 'styles4']; - assert.deepEqual(result, expected); -}); + it('grabs dependencies of stylus files', () => { + const fixture = fixturePath('styles.styl'); + const result = precinct.paperwork(fixture); + const expected = ['mystyles', 'styles2.styl', 'styles3.styl', 'styles4']; + expect(result).toStrictEqual(expected); + }); -test('grabs dependencies of less files', async() => { - const fixture = await readFixture('styles.less'); - const result = precinct(fixture, { type: 'less' }); - const expected = ['_foo', '_bar.css', 'baz.less']; - assert.deepEqual(result, expected); + it('grabs dependencies of less files', async() => { + const fixture = await readFixture('styles.less'); + const result = precinct(fixture, { type: 'less' }); + const expected = ['_foo', '_bar.css', 'baz.less']; + expect(result).toStrictEqual(expected); + }); }); - -test.run(); diff --git a/test/typescript.test.js b/test/typescript.test.js index ee2bf9f..f641629 100644 --- a/test/typescript.test.js +++ b/test/typescript.test.js @@ -1,28 +1,25 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { readFixture } from './helpers.js'; -const test = suite('TypeScript'); +describe('TypeScript', () => { + it('grabs dependencies of ts files', async() => { + const fixture = await readFixture('typescript.ts'); + const result = precinct(fixture, { type: 'ts' }); + const expected = ['fs', 'lib', './bar', './my-module.js', './ZipCodeValidator']; + expect(result).toStrictEqual(expected); + }); -test('grabs dependencies of ts files', async() => { - const fixture = await readFixture('typescript.ts'); - const result = precinct(fixture, { type: 'ts' }); - const expected = ['fs', 'lib', './bar', './my-module.js', './ZipCodeValidator']; - assert.deepEqual(result, expected); -}); - -test('grabs dependencies of tsx files', async() => { - const fixture = await readFixture('module.tsx'); - const result = precinct(fixture, { type: 'tsx' }); - const expected = ['./none']; - assert.deepEqual(result, expected); -}); + it('grabs dependencies of tsx files', async() => { + const fixture = await readFixture('module.tsx'); + const result = precinct(fixture, { type: 'tsx' }); + const expected = ['./none']; + expect(result).toStrictEqual(expected); + }); -test('does not grab dependencies when there are syntax errors', async() => { - const fixture = await readFixture('typescriptWithError.ts'); - const result = precinct(fixture); - assert.equal(result.length, 0); + it('does not grab dependencies when there are syntax errors', async() => { + const fixture = await readFixture('typescriptWithError.ts'); + const result = precinct(fixture); + expect(result.length).toBe(0); + }); }); - -test.run(); diff --git a/test/vue.test.js b/test/vue.test.js index 146981b..26f84d3 100644 --- a/test/vue.test.js +++ b/test/vue.test.js @@ -1,22 +1,19 @@ -import { strict as assert } from 'node:assert'; -import { suite } from 'uvu'; +import { describe, it, expect } from 'vitest'; import precinct from '../index.js'; import { fixturePath } from './helpers.js'; -const test = suite('Vue'); +describe('Vue', () => { + it('grabs dependencies from typescript/scss files', () => { + const result = precinct.paperwork(fixturePath('ts.vue')); + expect(result[0]).toBe('./typescript'); + expect(result[1]).toBe('styles.scss'); + expect(result.length).toBe(2); + }); -test('grabs dependencies from typescript/scss files', () => { - const result = precinct.paperwork(fixturePath('ts.vue')); - assert.equal(result[0], './typescript'); - assert.equal(result[1], 'styles.scss'); - assert.equal(result.length, 2); + it('grabs dependencies from javascript/sass files', () => { + const result = precinct.paperwork(fixturePath('js.vue')); + expect(result[0]).toBe('./typescript'); + expect(result[1]).toBe('styles.scss'); + expect(result.length).toBe(2); + }); }); - -test('grabs dependencies from javascript/sass files', () => { - const result = precinct.paperwork(fixturePath('js.vue')); - assert.equal(result[0], './typescript'); - assert.equal(result[1], 'styles.scss'); - assert.equal(result.length, 2); -}); - -test.run(); diff --git a/vitest.config.js b/vitest.config.js new file mode 100644 index 0000000..e6a96ac --- /dev/null +++ b/vitest.config.js @@ -0,0 +1,11 @@ +import { defineConfig } from 'vitest/config'; + +export default defineConfig({ + test: { + include: ['test/**/*.test.js'], + coverage: { + provider: 'v8', + reporter: ['html', 'lcovonly', 'text'] + } + } +});