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 8f59e6e..0000000 --- a/.mocharc.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "check-leaks": false, - "timeout": 10000, - "throw-deprecation": true, - "trace-deprecation": true, - "trace-warnings": true, - "use-strict": true -} diff --git a/package-lock.json b/package-lock.json index 981d8fe..2006266 100644 --- a/package-lock.json +++ b/package-lock.json @@ -19,12 +19,9 @@ "dependency-tree": "bin/cli.js" }, "devDependencies": { - "c8": "^11.0.0", + "@vitest/coverage-v8": "^4.1.7", "debug": "^4.4.3", - "globals": "^17.6.0", - "mocha": "^11.7.5", - "mock-fs": "^5.5.0", - "sinon": "^22.0.0", + "vitest": "^4.1.7", "xo": "^2.0.2" }, "engines": { @@ -838,34 +835,6 @@ "url": "https://github.com/sponsors/nzakas" } }, - "node_modules/@isaacs/cliui": { - "version": "8.0.2", - "resolved": "https://registry.npmjs.org/@isaacs/cliui/-/cliui-8.0.2.tgz", - "integrity": "sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==", - "dev": true, - "license": "ISC", - "dependencies": { - "string-width": "^5.1.2", - "string-width-cjs": "npm:string-width@^4.2.0", - "strip-ansi": "^7.0.1", - "strip-ansi-cjs": "npm:strip-ansi@^6.0.1", - "wrap-ansi": "^8.1.0", - "wrap-ansi-cjs": "npm:wrap-ansi@^7.0.0" - }, - "engines": { - "node": ">=12" - } - }, - "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", @@ -966,6 +935,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", @@ -973,17 +952,6 @@ "dev": true, "license": "MIT" }, - "node_modules/@pkgjs/parseargs": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/@pkgjs/parseargs/-/parseargs-0.11.0.tgz", - "integrity": "sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg==", - "dev": true, - "license": "MIT", - "optional": true, - "engines": { - "node": ">=14" - } - }, "node_modules/@pkgr/core": { "version": "0.2.9", "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.2.9.tgz", @@ -997,6 +965,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", @@ -1030,46 +1299,12 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@sinonjs/commons": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/@sinonjs/commons/-/commons-3.0.1.tgz", - "integrity": "sha512-K3mCHKQ9sVh8o1C9cxkwxaOmXoAMlDxC1mYyHrjqOWEcBjYr76t96zL2zlj5dUGZ3HSw240X1qgH3Mjf1yJWpQ==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "type-detect": "4.0.8" - } - }, - "node_modules/@sinonjs/fake-timers": { - "version": "15.4.0", - "resolved": "https://registry.npmjs.org/@sinonjs/fake-timers/-/fake-timers-15.4.0.tgz", - "integrity": "sha512-DsG+8/LscQIQg68J6Ef3dv10u6nVyetYn923s3/sus5eaGfTo1of5WMZSLf0UJc9KDuKPilPH0UDJCjvNbDNCA==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@sinonjs/commons": "^3.0.1" - } - }, - "node_modules/@sinonjs/samsam": { - "version": "10.0.2", - "resolved": "https://registry.npmjs.org/@sinonjs/samsam/-/samsam-10.0.2.tgz", - "integrity": "sha512-8lVwD1Df1BmzoaOLhMcGGcz/Jyr5QY2KSB75/YK1QgKzoabTeLdIVyhXNZK9ojfSKSdirbXqdbsXXqP9/Ve8+A==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@sinonjs/commons": "^3.0.1", - "type-detect": "^4.1.0" - } - }, - "node_modules/@sinonjs/samsam/node_modules/type-detect": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.1.0.tgz", - "integrity": "sha512-Acylog8/luQ8L7il+geoSxhEkazvkslg7PSNKOX59mbB9cOveP5aq9h74Y7YU8yDpJwetzQQrfIwtf4Wp4LKcw==", + "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", - "engines": { - "node": ">=4" - } + "license": "MIT" }, "node_modules/@stylistic/eslint-plugin": { "version": "5.10.0", @@ -1134,6 +1369,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", @@ -1159,13 +1412,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", @@ -1717,6 +1963,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", @@ -1848,6 +2248,7 @@ "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -2022,6 +2423,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", @@ -2031,6 +2442,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", @@ -2100,13 +2540,6 @@ "node": ">=8" } }, - "node_modules/browser-stdout": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", - "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", - "dev": true, - "license": "ISC" - }, "node_modules/browserslist": { "version": "4.28.2", "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.28.2.tgz", @@ -2170,40 +2603,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", @@ -2264,19 +2663,6 @@ "node": ">=6" } }, - "node_modules/camelcase": { - "version": "6.3.0", - "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", - "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/caniuse-lite": { "version": "1.0.30001793", "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001793.tgz", @@ -2298,12 +2684,23 @@ ], "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", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, "license": "MIT", + "peer": true, "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -2322,22 +2719,6 @@ "dev": true, "license": "MIT" }, - "node_modules/chokidar": { - "version": "4.0.3", - "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.3.tgz", - "integrity": "sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==", - "dev": true, - "license": "MIT", - "dependencies": { - "readdirp": "^4.0.1" - }, - "engines": { - "node": ">= 14.16.0" - }, - "funding": { - "url": "https://paulmillr.com/funding/" - } - }, "node_modules/ci-info": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-4.4.0.tgz", @@ -2377,90 +2758,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/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/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/cliui/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==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, "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" }, @@ -2648,19 +2952,6 @@ } } }, - "node_modules/decamelize": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz", - "integrity": "sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", @@ -2747,6 +3038,16 @@ "url": "https://github.com/sponsors/ljharb" } }, + "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": "Apache-2.0", + "engines": { + "node": ">=8" + } + }, "node_modules/detective-amd": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/detective-amd/-/detective-amd-7.0.0.tgz", @@ -2879,16 +3180,6 @@ "typescript": "^5.4.4 || ^6.0.2" } }, - "node_modules/diff": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-7.0.0.tgz", - "integrity": "sha512-PJWHUb1RFevKCwaFA9RlG5tCd+FO5iRh9A8HEtkmBH2Li03iJriB6m6JIN4rGz3K3JLawI7/veA1xzRKP6ISBw==", - "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", @@ -2917,26 +3208,12 @@ "node": ">= 0.4" } }, - "node_modules/eastasianwidth": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/eastasianwidth/-/eastasianwidth-0.2.0.tgz", - "integrity": "sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==", - "dev": true, - "license": "MIT" - }, "node_modules/electron-to-chromium": { "version": "1.5.357", "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.5.357.tgz", "integrity": "sha512-NHlTIQDK8fmVwHwuIzmXYEJ1Ewq3D9wDNc0cWXxDGysP6Pb21giwGNkxiTifyKy/4SoPuN5l6GLP1W9Sv7zB2g==", "dev": true, - "license": "ISC" - }, - "node_modules/emoji-regex": { - "version": "9.2.2", - "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-9.2.2.tgz", - "integrity": "sha512-L18DaJsXSUk2+42pv8mLs5jJT2hqFkFE4j21wOmgbUqsZ2hL72NsUU785g9RXgo3s0ZNgVl42TiHp3ZtOv/Vyg==", - "dev": true, - "license": "MIT" + "license": "ISC" }, "node_modules/enhance-visitors": { "version": "1.0.0", @@ -3138,6 +3415,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", @@ -3998,6 +4282,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", @@ -4210,16 +4504,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/flat": { - "version": "5.0.2", - "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", - "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", - "dev": true, - "license": "BSD-3-Clause", - "bin": { - "flat": "cli.js" - } - }, "node_modules/flat-cache": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz", @@ -4257,21 +4541,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": { @@ -4347,16 +4629,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", @@ -4476,28 +4748,6 @@ "url": "https://github.com/privatenumber/get-tsconfig?sponsor=1" } }, - "node_modules/glob": { - "version": "10.5.0", - "resolved": "https://registry.npmjs.org/glob/-/glob-10.5.0.tgz", - "integrity": "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg==", - "deprecated": "Old versions of glob are not supported, and contain widely publicized security vulnerabilities, which have been fixed in the current version. Please update. Support for old versions may be purchased (at exorbitant rates) by contacting i@izs.me", - "dev": true, - "license": "ISC", - "dependencies": { - "foreground-child": "^3.1.0", - "jackspeak": "^3.1.2", - "minimatch": "^9.0.4", - "minipass": "^7.1.2", - "package-json-from-dist": "^1.0.0", - "path-scurry": "^1.11.1" - }, - "bin": { - "glob": "dist/esm/bin.mjs" - }, - "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", @@ -4709,16 +4959,6 @@ "node": ">= 0.4" } }, - "node_modules/he": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", - "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", - "dev": true, - "license": "MIT", - "bin": { - "he": "bin/he" - } - }, "node_modules/hermes-estree": { "version": "0.25.1", "resolved": "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.25.1.tgz", @@ -5027,16 +5267,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", @@ -5164,16 +5394,6 @@ "node": ">=0.10.0" } }, - "node_modules/is-path-inside": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", - "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/is-plain-obj": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-4.1.0.tgz", @@ -5308,19 +5528,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/is-unicode-supported": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", - "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/is-url-superb": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/is-url-superb/-/is-url-superb-4.0.0.tgz", @@ -5466,22 +5673,6 @@ "node": ">= 0.4" } }, - "node_modules/jackspeak": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/jackspeak/-/jackspeak-3.4.3.tgz", - "integrity": "sha512-OGlZQpz2yfahA/Rd1Y8Cd9SIEsqvXkLVoSw/cgwhnhFMDbsQFeZYoJJ7bIZBS9BcamUW96asq/npPWugM+RQBw==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "@isaacs/cliui": "^8.0.2" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - }, - "optionalDependencies": { - "@pkgjs/parseargs": "^0.11.0" - } - }, "node_modules/js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -5502,97 +5693,370 @@ "js-yaml": "bin/js-yaml.js" } }, - "node_modules/jsesc": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", - "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", + "node_modules/jsesc": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-3.1.0.tgz", + "integrity": "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA==", + "dev": true, + "license": "MIT", + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/json-buffer": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", + "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/json-parse-even-better-errors": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", + "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "dev": true, + "license": "MIT" + }, + "node_modules/json-schema-traverse": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", + "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "dev": true, + "license": "MIT" + }, + "node_modules/json-stable-stringify-without-jsonify": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", + "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", + "dev": true, + "license": "MIT" + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "license": "MIT", + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/jsx-ast-utils": { + "version": "3.3.5", + "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", + "integrity": "sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "array-includes": "^3.1.6", + "array.prototype.flat": "^1.3.1", + "object.assign": "^4.1.4", + "object.values": "^1.1.6" + }, + "engines": { + "node": ">=4.0" + } + }, + "node_modules/keyv": { + "version": "4.5.4", + "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", + "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", + "dev": true, + "license": "MIT", + "dependencies": { + "json-buffer": "3.0.1" + } + }, + "node_modules/levn": { + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", + "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "prelude-ls": "^1.2.1", + "type-check": "~0.4.0" + }, + "engines": { + "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": "MIT", - "bin": { - "jsesc": "bin/jsesc" - }, + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=6" + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, - "node_modules/json-buffer": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-parse-even-better-errors": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz", - "integrity": "sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==", + "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, - "license": "MIT" + "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/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", + "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, - "license": "MIT" + "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/json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", + "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, - "license": "MIT" - }, - "node_modules/json5": { - "version": "2.2.3", - "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", - "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", - "license": "MIT", - "bin": { - "json5": "lib/cli.js" - }, + "libc": [ + "glibc" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=6" + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, - "node_modules/jsx-ast-utils": { - "version": "3.3.5", - "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", - "integrity": "sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==", + "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, - "license": "MIT", - "dependencies": { - "array-includes": "^3.1.6", - "array.prototype.flat": "^1.3.1", - "object.assign": "^4.1.4", - "object.values": "^1.1.6" - }, + "libc": [ + "musl" + ], + "license": "MPL-2.0", + "optional": true, + "os": [ + "linux" + ], "engines": { - "node": ">=4.0" + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, - "node_modules/keyv": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", + "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": "MIT", - "dependencies": { - "json-buffer": "3.0.1" + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, - "node_modules/levn": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", + "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": "MIT", - "dependencies": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" - }, + "license": "MPL-2.0", + "optional": true, + "os": [ + "win32" + ], "engines": { - "node": ">= 0.8.0" + "node": ">= 12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/parcel" } }, "node_modules/line-column-path": { @@ -5649,23 +6113,6 @@ "license": "MIT", "peer": true }, - "node_modules/log-symbols": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", - "dev": true, - "license": "MIT", - "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/loose-envify": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz", @@ -5679,13 +6126,6 @@ "loose-envify": "cli.js" } }, - "node_modules/lru-cache": { - "version": "10.4.3", - "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", - "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", - "dev": true, - "license": "ISC" - }, "node_modules/magic-string": { "version": "0.30.21", "resolved": "https://registry.npmjs.org/magic-string/-/magic-string-0.30.21.tgz", @@ -5695,6 +6135,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", @@ -5765,122 +6217,49 @@ "dev": true, "license": "MIT", "dependencies": { - "braces": "^3.0.3", - "picomatch": "^2.3.1" - }, - "engines": { - "node": ">=8.6" - } - }, - "node_modules/micromatch/node_modules/picomatch": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.2.tgz", - "integrity": "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8.6" - }, - "funding": { - "url": "https://github.com/sponsors/jonschlinkert" - } - }, - "node_modules/minimatch": { - "version": "9.0.9", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", - "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", - "dev": true, - "license": "ISC", - "dependencies": { - "brace-expansion": "^2.0.2" - }, - "engines": { - "node": ">=16 || 14 >=14.17" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/minimist": { - "version": "1.2.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", - "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", - "license": "MIT", - "funding": { - "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/mocha": { - "version": "11.7.5", - "resolved": "https://registry.npmjs.org/mocha/-/mocha-11.7.5.tgz", - "integrity": "sha512-mTT6RgopEYABzXWFx+GcJ+ZQ32kp4fMf0xvpZIIfSq9Z8lC/++MtcCnQ9t5FP2veYEP95FIYSvW+U9fV4xrlig==", - "dev": true, - "license": "MIT", - "dependencies": { - "browser-stdout": "^1.3.1", - "chokidar": "^4.0.1", - "debug": "^4.3.5", - "diff": "^7.0.0", - "escape-string-regexp": "^4.0.0", - "find-up": "^5.0.0", - "glob": "^10.4.5", - "he": "^1.2.0", - "is-path-inside": "^3.0.3", - "js-yaml": "^4.1.0", - "log-symbols": "^4.1.0", - "minimatch": "^9.0.5", - "ms": "^2.1.3", - "picocolors": "^1.1.1", - "serialize-javascript": "^6.0.2", - "strip-json-comments": "^3.1.1", - "supports-color": "^8.1.1", - "workerpool": "^9.2.0", - "yargs": "^17.7.2", - "yargs-parser": "^21.1.1", - "yargs-unparser": "^2.0.0" - }, - "bin": { - "_mocha": "bin/_mocha", - "mocha": "bin/mocha.js" + "braces": "^3.0.3", + "picomatch": "^2.3.1" }, "engines": { - "node": "^18.18.0 || ^20.9.0 || >=21.1.0" + "node": ">=8.6" } }, - "node_modules/mocha/node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "node_modules/micromatch/node_modules/picomatch": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.2.tgz", + "integrity": "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==", "dev": true, "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/minimatch": { + "version": "9.0.9", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-9.0.9.tgz", + "integrity": "sha512-OBwBN9AL4dqmETlpS2zasx+vTeWclWzkblfZk7KTA5j3jeOONz/tRCnZomUyvNg83wL5Zv9Ss6HMJXAgL8R2Yg==", + "dev": true, + "license": "ISC", "dependencies": { - "has-flag": "^4.0.0" + "brace-expansion": "^2.0.2" }, "engines": { - "node": ">=10" + "node": ">=16 || 14 >=14.17" }, "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" + "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/mock-fs": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/mock-fs/-/mock-fs-5.5.0.tgz", - "integrity": "sha512-d/P1M/RacgM3dB0sJ8rjeRNXxtapkPCUnMGmIN0ixJ16F/E4GUZCvWcSGfWGz8eaXYvn1s9baUwNjI4LOPEjiA==", - "dev": true, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", "license": "MIT", - "engines": { - "node": ">=12.0.0" + "funding": { + "url": "https://github.com/sponsors/ljharb" } }, "node_modules/module-definition": { @@ -6162,6 +6541,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", @@ -6270,13 +6660,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/package-json-from-dist": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/package-json-from-dist/-/package-json-from-dist-1.0.1.tgz", - "integrity": "sha512-UEZIS3/by4OC8vL3P2dTXRETpebLI2NiI5vIrjaD/5UtrkFX/tNbwjTSRAGC/+7CAo2pIcBaRgWmcBBHcsaCIw==", - "dev": true, - "license": "BlueOak-1.0.0" - }, "node_modules/parent-module": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", @@ -6348,22 +6731,12 @@ "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", "license": "MIT" }, - "node_modules/path-scurry": { - "version": "1.11.1", - "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-1.11.1.tgz", - "integrity": "sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==", + "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": "^10.2.0", - "minipass": "^5.0.0 || ^6.0.2 || ^7.0.0" - }, - "engines": { - "node": ">=16 || 14 >=14.18" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } + "license": "MIT" }, "node_modules/picocolors": { "version": "1.1.1", @@ -6626,16 +6999,6 @@ "integrity": "sha512-twwRO/ilhlG/FIgYeKGFqyHhoEhqgnKVkcmqMKi2r524gz3ZbDTcyFt38E9xjJI2vT+KbRNHVbnJ/e0I25Azwg==", "license": "MIT" }, - "node_modules/randombytes": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", - "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "safe-buffer": "^5.1.0" - } - }, "node_modules/react-is": { "version": "16.13.1", "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", @@ -6643,20 +7006,6 @@ "dev": true, "license": "MIT" }, - "node_modules/readdirp": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-4.1.2.tgz", - "integrity": "sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 14.18.0" - }, - "funding": { - "type": "individual", - "url": "https://paulmillr.com/funding/" - } - }, "node_modules/reflect.getprototypeof": { "version": "1.0.10", "resolved": "https://registry.npmjs.org/reflect.getprototypeof/-/reflect.getprototypeof-1.0.10.tgz", @@ -6724,16 +7073,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/requirejs": { "version": "2.3.8", "resolved": "https://registry.npmjs.org/requirejs/-/requirejs-2.3.8.tgz", @@ -6821,6 +7160,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", @@ -6878,27 +7251,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/safe-buffer": { - "version": "5.2.1", - "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true, - "funding": [ - { - "type": "github", - "url": "https://github.com/sponsors/feross" - }, - { - "type": "patreon", - "url": "https://www.patreon.com/feross" - }, - { - "type": "consulting", - "url": "https://feross.org/support" - } - ], - "license": "MIT" - }, "node_modules/safe-push-apply": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/safe-push-apply/-/safe-push-apply-1.0.0.tgz", @@ -6962,16 +7314,6 @@ "node": ">=10" } }, - "node_modules/serialize-javascript": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz", - "integrity": "sha512-Saa1xPByTTq2gdeFZYLLo+RFE35NHZkAbqZeWNd3BpzppeVisAqpDjcp8dyf6uIvEqJRd46jemmyA4iFIeVk8g==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "randombytes": "^2.1.0" - } - }, "node_modules/set-function-length": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", @@ -7120,6 +7462,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", @@ -7133,33 +7482,6 @@ "url": "https://github.com/sponsors/isaacs" } }, - "node_modules/sinon": { - "version": "22.0.0", - "resolved": "https://registry.npmjs.org/sinon/-/sinon-22.0.0.tgz", - "integrity": "sha512-sq/6DpdXOrLyfbKlXLg/Usc7xu8YXPeLkOFZRvA3bNUSA2lhbrZ06yuXbH1fkzBPCbz9O10+7hznzUsjaYNm0Q==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "@sinonjs/commons": "^3.0.1", - "@sinonjs/fake-timers": "^15.4.0", - "@sinonjs/samsam": "^10.0.2", - "diff": "^9.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/sinon" - } - }, - "node_modules/sinon/node_modules/diff": { - "version": "9.0.0", - "resolved": "https://registry.npmjs.org/diff/-/diff-9.0.0.tgz", - "integrity": "sha512-svtcdpS8CgJyqAjEQIXdb3OjhFVVYjzGAPO8WGCmRbrml64SPw/jJD4GoE98aR7r25A0XcgrK3F02yw9R/vhQw==", - "dev": true, - "license": "BSD-3-Clause", - "engines": { - "node": ">=0.3.1" - } - }, "node_modules/slash": { "version": "5.1.0", "resolved": "https://registry.npmjs.org/slash/-/slash-5.1.0.tgz", @@ -7202,6 +7524,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", @@ -7216,70 +7552,6 @@ "node": ">= 0.4" } }, - "node_modules/string-width": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-5.1.2.tgz", - "integrity": "sha512-HnLOCR3vjcY8beoNLtcjZ5/nxn2afmME6lhrDrebokqMap+XbeW8n9TXpPDOqdGK5qcI3oT0GKTW6wC7EMiVqA==", - "dev": true, - "license": "MIT", - "dependencies": { - "eastasianwidth": "^0.2.0", - "emoji-regex": "^9.2.2", - "strip-ansi": "^7.0.1" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/string-width-cjs": { - "name": "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/string-width-cjs/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/string-width-cjs/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/string-width-cjs/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/string.prototype.matchall": { "version": "4.0.12", "resolved": "https://registry.npmjs.org/string.prototype.matchall/-/string.prototype.matchall-4.0.12.tgz", @@ -7408,30 +7680,6 @@ "url": "https://github.com/chalk/strip-ansi?sponsor=1" } }, - "node_modules/strip-ansi-cjs": { - "name": "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/strip-ansi-cjs/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/strip-bom": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", @@ -7473,6 +7721,7 @@ "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", "dev": true, "license": "MIT", + "peer": true, "engines": { "node": ">=8" }, @@ -7586,122 +7835,40 @@ "dev": true, "license": "MIT", "engines": { - "node": ">=20" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/tapable": { - "version": "2.3.3", - "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.3.3.tgz", - "integrity": "sha512-uxc/zpqFg6x7C8vOE7lh6Lbda8eEL9zmVm/PLeTPBRhh1xCgdWaQ+J1CUieGpIfm2HdtsUpRv+HshiasBMcc6A==", - "license": "MIT", - "engines": { - "node": ">=6" - }, - "funding": { - "type": "opencollective", - "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==", - "dev": true, - "license": "ISC", - "dependencies": { - "@istanbuljs/schema": "^0.1.2", - "glob": "^13.0.6", - "minimatch": "^10.2.2" - }, - "engines": { - "node": "20 || >=22" - } - }, - "node_modules/test-exclude/node_modules/balanced-match": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-4.0.4.tgz", - "integrity": "sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/test-exclude/node_modules/brace-expansion": { - "version": "5.0.6", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.6.tgz", - "integrity": "sha512-kLpxurY4Z4r9sgMsyG0Z9uzsBlgiU/EFKhj/h91/8yHu0edo7XuixOIH3VcJ8kkxs6/jPzoI6U9Vj3WqbMQ94g==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^4.0.2" - }, - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/test-exclude/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/test-exclude/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": ">=20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/test-exclude/node_modules/minimatch": { - "version": "10.2.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.5.tgz", - "integrity": "sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "brace-expansion": "^5.0.5" - }, + "node_modules/tapable": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/tapable/-/tapable-2.3.3.tgz", + "integrity": "sha512-uxc/zpqFg6x7C8vOE7lh6Lbda8eEL9zmVm/PLeTPBRhh1xCgdWaQ+J1CUieGpIfm2HdtsUpRv+HshiasBMcc6A==", + "license": "MIT", "engines": { - "node": "18 || 20 || >=22" + "node": ">=6" }, "funding": { - "url": "https://github.com/sponsors/isaacs" + "type": "opencollective", + "url": "https://opencollective.com/webpack" } }, - "node_modules/test-exclude/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/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": "BlueOak-1.0.0", - "dependencies": { - "lru-cache": "^11.0.0", - "minipass": "^7.1.2" - }, + "license": "MIT" + }, + "node_modules/tinyexec": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/tinyexec/-/tinyexec-1.2.2.tgz", + "integrity": "sha512-M/Q0B2cp4K7kynaT/vnED1j8TlLY+Pp7C6Wl2bl/7u/F0mUVwdyOpwomQb8JpYLitHUssAJRmLZdMCGsrx7i+g==", + "dev": true, + "license": "MIT", "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" + "node": ">=18" } }, "node_modules/tinyglobby": { @@ -7720,6 +7887,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", @@ -7803,16 +7980,6 @@ "node": ">= 0.8.0" } }, - "node_modules/type-detect": { - "version": "4.0.8", - "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=4" - } - }, "node_modules/type-fest": { "version": "5.6.0", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-5.6.0.tgz", @@ -8052,19 +8219,172 @@ "punycode": "^2.1.0" } }, - "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/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": "ISC", + "license": "MIT", + "dependencies": { + "lightningcss": "^1.32.0", + "picomatch": "^4.0.4", + "postcss": "^8.5.15", + "rolldown": "1.0.2", + "tinyglobby": "^0.2.16" + }, + "bin": { + "vite": "bin/vite.js" + }, + "engines": { + "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/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": "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": { @@ -8172,116 +8492,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/workerpool": { - "version": "9.3.4", - "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-9.3.4.tgz", - "integrity": "sha512-TmPRQYYSAnnDiEB0P/Ytip7bFGvqnSU6I2BcuSw7Hx+JSg/DsUi5ebYfc8GYaSdpuvOcEs6dXxPurOYpe9QFwg==", - "dev": true, - "license": "Apache-2.0" - }, - "node_modules/wrap-ansi": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-8.1.0.tgz", - "integrity": "sha512-si7QWI6zUMq56bESFvagtmzMdGOtoxfR+Sez11Mobfc7tm+VkUckk9bW2UeffTGVUbOksxmSw0AA2gs8g71NCQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^6.1.0", - "string-width": "^5.0.1", - "strip-ansi": "^7.0.1" - }, - "engines": { - "node": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/wrap-ansi-cjs": { - "name": "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==", - "dev": true, - "license": "MIT", - "dependencies": { - "ansi-styles": "^4.0.0", - "string-width": "^4.1.0", - "strip-ansi": "^6.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/wrap-ansi?sponsor=1" - } - }, - "node_modules/wrap-ansi-cjs/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-cjs/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/wrap-ansi-cjs/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==", + "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": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" + "siginfo": "^2.0.0", + "stackback": "0.0.2" }, - "engines": { - "node": ">=8" - } - }, - "node_modules/wrap-ansi-cjs/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" + "bin": { + "why-is-node-running": "cli.js" }, "engines": { "node": ">=8" } }, - "node_modules/wrap-ansi/node_modules/ansi-styles": { - "version": "6.2.3", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-6.2.3.tgz", - "integrity": "sha512-4Dj6M28JB+oAH8kFkTLUo+a2jwOFkuqb3yucU0CANcRRUbxS0cP0nZYCGjcc3BNXwRIsUVmDGgzawme7zvJHvg==", + "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": ">=12" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" + "node": ">=0.10.0" } }, "node_modules/wsl-utils": { @@ -8625,16 +8860,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", @@ -8642,106 +8867,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-unparser": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz", - "integrity": "sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==", - "dev": true, - "license": "MIT", - "dependencies": { - "camelcase": "^6.0.0", - "decamelize": "^4.0.0", - "flat": "^5.0.2", - "is-plain-obj": "^2.1.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/yargs-unparser/node_modules/is-plain-obj": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", - "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, - "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/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/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 c3891c4..260beb4 100644 --- a/package.json +++ b/package.json @@ -23,9 +23,9 @@ "check:types": "npm run generate:types && git diff HEAD --exit-code types/index.d.ts", "lint": "xo", "fix": "xo --fix", - "mocha": "mocha \"test/*.test.js\"", - "test": "npm run lint && npm run check:types && npm run mocha", - "test:ci": "c8 npm run mocha" + "vitest": "vitest", + "test": "npm run lint && npm run check:types && vitest run", + "test:ci": "vitest run --coverage" }, "repository": { "type": "git", @@ -63,12 +63,9 @@ "typescript": "^6.0.3" }, "devDependencies": { - "c8": "^11.0.0", + "@vitest/coverage-v8": "^4.1.7", "debug": "^4.4.3", - "globals": "^17.6.0", - "mocha": "^11.7.5", - "mock-fs": "^5.5.0", - "sinon": "^22.0.0", + "vitest": "^4.1.7", "xo": "^2.0.2" } } diff --git a/test/cli.test.js b/test/cli.test.js index 9567ebf..386a9fe 100644 --- a/test/cli.test.js +++ b/test/cli.test.js @@ -1,10 +1,10 @@ -import { strict as assert } from 'node:assert'; import { spawnSync } from 'node:child_process'; import fs from 'node:fs'; import os from 'node:os'; import path from 'node:path'; import process from 'node:process'; import { fileURLToPath } from 'node:url'; +import { describe, it, expect } from 'vitest'; import { fixtures } from './helpers.js'; const cliPath = fileURLToPath(new URL('../bin/cli.js', import.meta.url)); @@ -15,9 +15,9 @@ describe('cli', () => { encoding: 'utf8' }); - assert.equal(result.status, 1); - assert.match(result.stderr, /error: missing required argument 'filename'/); - assert.match(result.stderr, /Usage: dependency-tree \[options] /); + expect(result.status).toBe(1); + expect(result.stderr).toMatch(/error: missing required argument 'filename'/); + expect(result.stderr).toMatch(/Usage: dependency-tree \[options] /); }); describe('--es6-mixed-imports', () => { @@ -31,13 +31,13 @@ describe('cli', () => { { encoding: 'utf8' } ); - assert.equal(result.status, 0, result.stderr); + expect(result.status).toBe(0); const lines = result.stdout.trimEnd().split('\n'); const basenames = new Set(lines.map(line => path.basename(line))); - assert.ok(basenames.has('esm.js'), 'esm.js should be detected'); - assert.ok(basenames.has('cjs.js'), 'cjs.js should be detected'); + expect(basenames).toContain('esm.js'); + expect(basenames).toContain('cjs.js'); }); }); @@ -53,19 +53,17 @@ describe('cli', () => { { encoding: 'utf8' } ); - assert.equal(result.status, 0, result.stderr); + expect(result.status).toBe(0); const lines = result.stdout.trimEnd().split('\n'); - assert.equal(lines.length, 3); - assert.equal(path.resolve(lines.at(-1)), path.resolve(entry)); + expect(lines).toHaveLength(3); + expect(path.resolve(lines.at(-1))).toBe(path.resolve(entry)); }); }); describe('default (non-list) output', () => { - it('does not crash where JSON.stringify would exceed V8 string length limits (issue #141)', function() { - this.timeout(20_000); - + it('does not crash where JSON.stringify would exceed V8 string length limits (issue #141)', () => { // Build a diamond dependency fixture: every pair at depth k requires both // files at depth k+1. traverse() memoises via config.visited and returns // the SAME JS object reference for every re-visit of a file, so @@ -104,10 +102,10 @@ describe('cli', () => { { stdio: ['ignore', 'ignore', 'pipe'], encoding: 'utf8' } ); - assert.equal(result.status, 0, result.stderr); + expect(result.status).toBe(0); } finally { fs.rmSync(tmpDir, { recursive: true, force: true }); } - }); + }, 20_000); }); }); diff --git a/test/config.test.js b/test/config.test.js index 48d2b25..4f78ac7 100644 --- a/test/config.test.js +++ b/test/config.test.js @@ -1,11 +1,11 @@ -import { strict as assert } from 'node:assert'; import path from 'node:path'; +import { describe, it, expect } from 'vitest'; import Config from '../lib/config.js'; import dependencyTree from '../index.js'; import { fixtures } from './helpers.js'; describe('Config', () => { - it('pre-parses tsconfig for performance', () => { + describe('with a tsConfig path', () => { const tsConfigPath = fixtures('ts', '.tsconfig'); const config = new Config({ filename: 'foo', @@ -13,18 +13,13 @@ describe('Config', () => { tsConfig: tsConfigPath }); - assert.equal(typeof config.tsConfig, 'object'); - }); - - it('includes tsConfigPath so filing-cabinet can resolve compilerOptions.paths', () => { - const tsConfigPath = fixtures('ts', '.tsconfig'); - const config = new Config({ - filename: 'foo', - directory: 'bar', - tsConfig: tsConfigPath + it('pre-parses tsconfig for performance', () => { + expect(config.tsConfig).toBeTypeOf('object'); }); - assert.equal(config.tsConfigPath, tsConfigPath); + it('includes tsConfigPath so filing-cabinet can resolve compilerOptions.paths', () => { + expect(config.tsConfigPath).toBe(tsConfigPath); + }); }); it('retains detective config in the clone', () => { @@ -42,7 +37,7 @@ describe('Config', () => { const clone = config.clone(); - assert.deepEqual(clone.detectiveConfig, detectiveConfig); + expect(clone.detectiveConfig).toStrictEqual(detectiveConfig); }); }); @@ -59,8 +54,8 @@ describe('noTypeDefinitions', () => { noTypeDefinitions: false }); - assert.equal(list.includes(dtsPath), true); - assert.equal(list.includes(jsPath), false); + expect(list).toContain(dtsPath); + expect(list).not.toContain(jsPath); }); it('resolves to JavaScript files when set to true', () => { @@ -70,7 +65,7 @@ describe('noTypeDefinitions', () => { noTypeDefinitions: true }); - assert.equal(list.includes(jsPath), true); - assert.equal(list.includes(dtsPath), false); + expect(list).toContain(jsPath); + expect(list).not.toContain(dtsPath); }); }); diff --git a/test/fixtures/cjs/bar.js b/test/fixtures/cjs/bar.js new file mode 100644 index 0000000..bd816ea --- /dev/null +++ b/test/fixtures/cjs/bar.js @@ -0,0 +1 @@ +module.exports = 1; diff --git a/test/fixtures/cjs/foo.js b/test/fixtures/cjs/foo.js new file mode 100644 index 0000000..c3208c5 --- /dev/null +++ b/test/fixtures/cjs/foo.js @@ -0,0 +1 @@ +module.exports = function(bar = require("./bar")) {}; diff --git a/test/fixtures/cyclic/a.js b/test/fixtures/cyclic/a.js new file mode 100644 index 0000000..58fd5fb --- /dev/null +++ b/test/fixtures/cyclic/a.js @@ -0,0 +1 @@ +var b = require("./b"); diff --git a/test/fixtures/cyclic/b.js b/test/fixtures/cyclic/b.js new file mode 100644 index 0000000..3043adb --- /dev/null +++ b/test/fixtures/cyclic/b.js @@ -0,0 +1 @@ +var a = require("./a"); diff --git a/test/fixtures/directNodeModules/a.js b/test/fixtures/directNodeModules/a.js new file mode 100644 index 0000000..f1377e9 --- /dev/null +++ b/test/fixtures/directNodeModules/a.js @@ -0,0 +1 @@ +var x = require("./node_modules/direct"); diff --git a/test/fixtures/directNodeModules/node_modules/direct.js b/test/fixtures/directNodeModules/node_modules/direct.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/directNodeModules/node_modules/direct.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/duplicateModules/a.js b/test/fixtures/duplicateModules/a.js new file mode 100644 index 0000000..ee5dbbd --- /dev/null +++ b/test/fixtures/duplicateModules/a.js @@ -0,0 +1,2 @@ +import b from "./b"; +import c from "./c"; diff --git a/test/fixtures/duplicateModules/b.js b/test/fixtures/duplicateModules/b.js new file mode 100644 index 0000000..4a98f6f --- /dev/null +++ b/test/fixtures/duplicateModules/b.js @@ -0,0 +1 @@ +import c from "./c"; diff --git a/test/fixtures/duplicateModules/c.js b/test/fixtures/duplicateModules/c.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/duplicateModules/c.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/es6/a.js b/test/fixtures/es6/a.js new file mode 100644 index 0000000..b7c7498 --- /dev/null +++ b/test/fixtures/es6/a.js @@ -0,0 +1,2 @@ +import b from './b'; +import c from './c'; diff --git a/test/fixtures/es6/b.js b/test/fixtures/es6/b.js new file mode 100644 index 0000000..6ab80bc --- /dev/null +++ b/test/fixtures/es6/b.js @@ -0,0 +1 @@ +export default function() {} diff --git a/test/fixtures/es6/c.js b/test/fixtures/es6/c.js new file mode 100644 index 0000000..6ab80bc --- /dev/null +++ b/test/fixtures/es6/c.js @@ -0,0 +1 @@ +export default function() {} diff --git a/test/fixtures/es6/dynamicImports/bar.js b/test/fixtures/es6/dynamicImports/bar.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/es6/dynamicImports/bar.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/es6/dynamicImports/foo.js b/test/fixtures/es6/dynamicImports/foo.js new file mode 100644 index 0000000..710dbe0 --- /dev/null +++ b/test/fixtures/es6/dynamicImports/foo.js @@ -0,0 +1 @@ +import("./bar"); diff --git a/test/fixtures/es6/es7.js b/test/fixtures/es6/es7.js new file mode 100644 index 0000000..36e625f --- /dev/null +++ b/test/fixtures/es6/es7.js @@ -0,0 +1,2 @@ +import c from "./c"; +export default async function foo() {} diff --git a/test/fixtures/es6/foo.jsx b/test/fixtures/es6/foo.jsx new file mode 100644 index 0000000..5331fd0 --- /dev/null +++ b/test/fixtures/es6/foo.jsx @@ -0,0 +1,3 @@ +import React from "react"; +import b from "./b"; +export default ; diff --git a/test/fixtures/es6/jsx.js b/test/fixtures/es6/jsx.js new file mode 100644 index 0000000..bbcce3d --- /dev/null +++ b/test/fixtures/es6/jsx.js @@ -0,0 +1,2 @@ +import c from "./c"; +export default ; diff --git a/test/fixtures/es6/lazyRequires/bar.js b/test/fixtures/es6/lazyRequires/bar.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/es6/lazyRequires/bar.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/es6/lazyRequires/foo.js b/test/fixtures/es6/lazyRequires/foo.js new file mode 100644 index 0000000..5e25f36 --- /dev/null +++ b/test/fixtures/es6/lazyRequires/foo.js @@ -0,0 +1 @@ +export default function(bar = require("./bar")) {}; diff --git a/test/fixtures/es6/moduleEntry/module.entry.js b/test/fixtures/es6/moduleEntry/module.entry.js new file mode 100644 index 0000000..d37b5ec --- /dev/null +++ b/test/fixtures/es6/moduleEntry/module.entry.js @@ -0,0 +1 @@ +import * as module from "module.entry" diff --git a/test/fixtures/es6/moduleEntry/node_modules/module.entry/index.main.js b/test/fixtures/es6/moduleEntry/node_modules/module.entry/index.main.js new file mode 100644 index 0000000..0a55f34 --- /dev/null +++ b/test/fixtures/es6/moduleEntry/node_modules/module.entry/index.main.js @@ -0,0 +1 @@ +module.exports = function() {}; diff --git a/test/fixtures/es6/moduleEntry/node_modules/module.entry/index.module.js b/test/fixtures/es6/moduleEntry/node_modules/module.entry/index.module.js new file mode 100644 index 0000000..0a55f34 --- /dev/null +++ b/test/fixtures/es6/moduleEntry/node_modules/module.entry/index.module.js @@ -0,0 +1 @@ +module.exports = function() {}; diff --git a/test/fixtures/es6/moduleEntry/node_modules/module.entry/package.json b/test/fixtures/es6/moduleEntry/node_modules/module.entry/package.json new file mode 100644 index 0000000..f635211 --- /dev/null +++ b/test/fixtures/es6/moduleEntry/node_modules/module.entry/package.json @@ -0,0 +1,4 @@ +{ + "main": "index.main.js", + "module": "index.module.js" +} diff --git a/test/fixtures/es6/parentChild/module.entry.js b/test/fixtures/es6/parentChild/module.entry.js new file mode 100644 index 0000000..71aa35a --- /dev/null +++ b/test/fixtures/es6/parentChild/module.entry.js @@ -0,0 +1 @@ +import * as module from "parent_module_a" diff --git a/test/fixtures/es6/parentChild/node_modules/child_node_module/index.main.js b/test/fixtures/es6/parentChild/node_modules/child_node_module/index.main.js new file mode 100644 index 0000000..8ba7376 --- /dev/null +++ b/test/fixtures/es6/parentChild/node_modules/child_node_module/index.main.js @@ -0,0 +1 @@ +module.exports = "child_node_module" diff --git a/test/fixtures/es6/parentChild/node_modules/child_node_module/package.json b/test/fixtures/es6/parentChild/node_modules/child_node_module/package.json new file mode 100644 index 0000000..42e11c0 --- /dev/null +++ b/test/fixtures/es6/parentChild/node_modules/child_node_module/package.json @@ -0,0 +1,4 @@ +{ + "main": "index.main.js", + "version": "2.0.0" +} diff --git a/test/fixtures/es6/parentChild/node_modules/parent_module_a/index.main.js b/test/fixtures/es6/parentChild/node_modules/parent_module_a/index.main.js new file mode 100644 index 0000000..41366ac --- /dev/null +++ b/test/fixtures/es6/parentChild/node_modules/parent_module_a/index.main.js @@ -0,0 +1,2 @@ +import * as child_module from "child_node_module"; +module.exports = child_module; diff --git a/test/fixtures/es6/parentChild/node_modules/parent_module_a/node_modules/child_node_module/index.main.js b/test/fixtures/es6/parentChild/node_modules/parent_module_a/node_modules/child_node_module/index.main.js new file mode 100644 index 0000000..2090158 --- /dev/null +++ b/test/fixtures/es6/parentChild/node_modules/parent_module_a/node_modules/child_node_module/index.main.js @@ -0,0 +1 @@ +module.exports = "child_node_module_of_parent_a" diff --git a/test/fixtures/es6/parentChild/node_modules/parent_module_a/node_modules/child_node_module/package.json b/test/fixtures/es6/parentChild/node_modules/parent_module_a/node_modules/child_node_module/package.json new file mode 100644 index 0000000..2c3cf98 --- /dev/null +++ b/test/fixtures/es6/parentChild/node_modules/parent_module_a/node_modules/child_node_module/package.json @@ -0,0 +1,4 @@ +{ + "main": "index.main.js", + "version": "1.0.0" +} diff --git a/test/fixtures/es6/parentChild/node_modules/parent_module_a/package.json b/test/fixtures/es6/parentChild/node_modules/parent_module_a/package.json new file mode 100644 index 0000000..9f0df9b --- /dev/null +++ b/test/fixtures/es6/parentChild/node_modules/parent_module_a/package.json @@ -0,0 +1,3 @@ +{ + "main": "index.main.js" +} diff --git a/test/fixtures/flat-nm/a.js b/test/fixtures/flat-nm/a.js new file mode 100644 index 0000000..47eedd9 --- /dev/null +++ b/test/fixtures/flat-nm/a.js @@ -0,0 +1 @@ +var x = require("flatmod"); diff --git a/test/fixtures/flat-nm/node_modules/flatmod.js b/test/fixtures/flat-nm/node_modules/flatmod.js new file mode 100644 index 0000000..bd816ea --- /dev/null +++ b/test/fixtures/flat-nm/node_modules/flatmod.js @@ -0,0 +1 @@ +module.exports = 1; diff --git a/test/fixtures/imaginary/.gitkeep b/test/fixtures/imaginary/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/test/fixtures/less/a.less b/test/fixtures/less/a.less new file mode 100644 index 0000000..bb512f6 --- /dev/null +++ b/test/fixtures/less/a.less @@ -0,0 +1,2 @@ +@import "b.css"; +@import "c.less"; diff --git a/test/fixtures/less/b.css b/test/fixtures/less/b.css new file mode 100644 index 0000000..7614dc7 --- /dev/null +++ b/test/fixtures/less/b.css @@ -0,0 +1 @@ +body { color: blue; } diff --git a/test/fixtures/less/c.less b/test/fixtures/less/c.less new file mode 100644 index 0000000..77557c7 --- /dev/null +++ b/test/fixtures/less/c.less @@ -0,0 +1 @@ +body { color: pink; } diff --git a/test/fixtures/missingSassPartial/a.scss b/test/fixtures/missingSassPartial/a.scss new file mode 100644 index 0000000..14b2755 --- /dev/null +++ b/test/fixtures/missingSassPartial/a.scss @@ -0,0 +1 @@ +@import "missing-partial"; diff --git a/test/fixtures/mixedPartials/a.js b/test/fixtures/mixedPartials/a.js new file mode 100644 index 0000000..58fd5fb --- /dev/null +++ b/test/fixtures/mixedPartials/a.js @@ -0,0 +1 @@ +var b = require("./b"); diff --git a/test/fixtures/mixedPartials/b.js b/test/fixtures/mixedPartials/b.js new file mode 100644 index 0000000..f741a73 --- /dev/null +++ b/test/fixtures/mixedPartials/b.js @@ -0,0 +1 @@ +var c = require("./c"); export default 1; diff --git a/test/fixtures/mixedPartials/c.js b/test/fixtures/mixedPartials/c.js new file mode 100644 index 0000000..bac3481 --- /dev/null +++ b/test/fixtures/mixedPartials/c.js @@ -0,0 +1 @@ +var crap = require("./notRealMan"); diff --git a/test/fixtures/nestedNodeModules/a.js b/test/fixtures/nestedNodeModules/a.js new file mode 100644 index 0000000..1ac0edb --- /dev/null +++ b/test/fixtures/nestedNodeModules/a.js @@ -0,0 +1 @@ +var x = require("./node_modules/pkg-a/index"); diff --git a/test/fixtures/nestedNodeModules/node_modules/pkg-a/index.js b/test/fixtures/nestedNodeModules/node_modules/pkg-a/index.js new file mode 100644 index 0000000..56c81a8 --- /dev/null +++ b/test/fixtures/nestedNodeModules/node_modules/pkg-a/index.js @@ -0,0 +1 @@ +var y = require("./node_modules/pkg-b/index"); diff --git a/test/fixtures/nestedNodeModules/node_modules/pkg-a/node_modules/pkg-b/index.js b/test/fixtures/nestedNodeModules/node_modules/pkg-a/node_modules/pkg-b/index.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/nestedNodeModules/node_modules/pkg-a/node_modules/pkg-b/index.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/nodeModulesInName/a.js b/test/fixtures/nodeModulesInName/a.js new file mode 100644 index 0000000..4b5ec14 --- /dev/null +++ b/test/fixtures/nodeModulesInName/a.js @@ -0,0 +1 @@ +var x = require("./node_modules.helper"); diff --git a/test/fixtures/nodeModulesInName/node_modules.helper.js b/test/fixtures/nodeModulesInName/node_modules.helper.js new file mode 100644 index 0000000..979a9d5 --- /dev/null +++ b/test/fixtures/nodeModulesInName/node_modules.helper.js @@ -0,0 +1 @@ +var y = require("./sub"); diff --git a/test/fixtures/nodeModulesInName/sub.js b/test/fixtures/nodeModulesInName/sub.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/nodeModulesInName/sub.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/onlyMissingDep/a.js b/test/fixtures/onlyMissingDep/a.js new file mode 100644 index 0000000..fa472f2 --- /dev/null +++ b/test/fixtures/onlyMissingDep/a.js @@ -0,0 +1 @@ +var notReal = require("./notReal"); diff --git a/test/fixtures/repeatedMissing/a.js b/test/fixtures/repeatedMissing/a.js new file mode 100644 index 0000000..9669300 --- /dev/null +++ b/test/fixtures/repeatedMissing/a.js @@ -0,0 +1,2 @@ +var b = require("./b"); +var crap = require("./notRealMan"); diff --git a/test/fixtures/repeatedMissing/b.js b/test/fixtures/repeatedMissing/b.js new file mode 100644 index 0000000..f741a73 --- /dev/null +++ b/test/fixtures/repeatedMissing/b.js @@ -0,0 +1 @@ +var c = require("./c"); export default 1; diff --git a/test/fixtures/repeatedMissing/c.js b/test/fixtures/repeatedMissing/c.js new file mode 100644 index 0000000..bac3481 --- /dev/null +++ b/test/fixtures/repeatedMissing/c.js @@ -0,0 +1 @@ +var crap = require("./notRealMan"); diff --git a/test/fixtures/requirejs/phantom/a.js b/test/fixtures/requirejs/phantom/a.js new file mode 100644 index 0000000..eaafe6f --- /dev/null +++ b/test/fixtures/requirejs/phantom/a.js @@ -0,0 +1 @@ +define(["phantom"], function(p) {}); diff --git a/test/fixtures/requirejs/phantom/require.config.js b/test/fixtures/requirejs/phantom/require.config.js new file mode 100644 index 0000000..6d16576 --- /dev/null +++ b/test/fixtures/requirejs/phantom/require.config.js @@ -0,0 +1,6 @@ +requirejs.config({ + baseUrl: './', + paths: { + phantom: './phantom-module' + } +}); diff --git a/test/fixtures/requirejs/root/a.js b/test/fixtures/requirejs/root/a.js new file mode 100644 index 0000000..ecd03b1 --- /dev/null +++ b/test/fixtures/requirejs/root/a.js @@ -0,0 +1,5 @@ +define([ + 'F' +], function(F) { + +}); diff --git a/test/fixtures/requirejs/root/b.js b/test/fixtures/requirejs/root/b.js new file mode 100644 index 0000000..0709fcb --- /dev/null +++ b/test/fixtures/requirejs/root/b.js @@ -0,0 +1,5 @@ +define([ + './lodizzle' +], function(F) { + +}); diff --git a/test/fixtures/requirejs/root/lodizzle.js b/test/fixtures/requirejs/root/lodizzle.js new file mode 100644 index 0000000..962ddd2 --- /dev/null +++ b/test/fixtures/requirejs/root/lodizzle.js @@ -0,0 +1 @@ +define({}) diff --git a/test/fixtures/requirejs/root/require.config.js b/test/fixtures/requirejs/root/require.config.js new file mode 100644 index 0000000..35d02ab --- /dev/null +++ b/test/fixtures/requirejs/root/require.config.js @@ -0,0 +1,6 @@ +requirejs.config({ + baseUrl: './', + paths: { + F: './lodizzle.js' + } +}); diff --git a/test/fixtures/sass/_b.scss b/test/fixtures/sass/_b.scss new file mode 100644 index 0000000..7614dc7 --- /dev/null +++ b/test/fixtures/sass/_b.scss @@ -0,0 +1 @@ +body { color: blue; } diff --git a/test/fixtures/sass/_c.scss b/test/fixtures/sass/_c.scss new file mode 100644 index 0000000..77557c7 --- /dev/null +++ b/test/fixtures/sass/_c.scss @@ -0,0 +1 @@ +body { color: pink; } diff --git a/test/fixtures/sass/a.scss b/test/fixtures/sass/a.scss new file mode 100644 index 0000000..7b00a2c --- /dev/null +++ b/test/fixtures/sass/a.scss @@ -0,0 +1,2 @@ +@import "_b"; +@import "_c.scss"; diff --git a/test/fixtures/scoped-nm/a.js b/test/fixtures/scoped-nm/a.js new file mode 100644 index 0000000..0b82306 --- /dev/null +++ b/test/fixtures/scoped-nm/a.js @@ -0,0 +1 @@ +var x = require("@scope/pkg"); diff --git a/test/fixtures/scoped-nm/node_modules/@scope/pkg/index.js b/test/fixtures/scoped-nm/node_modules/@scope/pkg/index.js new file mode 100644 index 0000000..bd816ea --- /dev/null +++ b/test/fixtures/scoped-nm/node_modules/@scope/pkg/index.js @@ -0,0 +1 @@ +module.exports = 1; diff --git a/test/fixtures/scoped-nm/node_modules/@scope/pkg/package.json b/test/fixtures/scoped-nm/node_modules/@scope/pkg/package.json new file mode 100644 index 0000000..14ab704 --- /dev/null +++ b/test/fixtures/scoped-nm/node_modules/@scope/pkg/package.json @@ -0,0 +1,3 @@ +{ + "main": "index.js" +} diff --git a/test/fixtures/scopedPackage/a.js b/test/fixtures/scopedPackage/a.js new file mode 100644 index 0000000..0a82e31 --- /dev/null +++ b/test/fixtures/scopedPackage/a.js @@ -0,0 +1 @@ +var x = require("./node_modules/@scope/pkg/index"); diff --git a/test/fixtures/scopedPackage/node_modules/@scope/pkg/index.js b/test/fixtures/scopedPackage/node_modules/@scope/pkg/index.js new file mode 100644 index 0000000..9568234 --- /dev/null +++ b/test/fixtures/scopedPackage/node_modules/@scope/pkg/index.js @@ -0,0 +1 @@ +var y = require("./util"); diff --git a/test/fixtures/scopedPackage/node_modules/@scope/pkg/util.js b/test/fixtures/scopedPackage/node_modules/@scope/pkg/util.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/scopedPackage/node_modules/@scope/pkg/util.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/fixtures/stylus/a.styl b/test/fixtures/stylus/a.styl new file mode 100644 index 0000000..177fc08 --- /dev/null +++ b/test/fixtures/stylus/a.styl @@ -0,0 +1,2 @@ +@import "b" +@require "c.styl" diff --git a/test/fixtures/stylus/b.styl b/test/fixtures/stylus/b.styl new file mode 100644 index 0000000..4cbbf92 --- /dev/null +++ b/test/fixtures/stylus/b.styl @@ -0,0 +1 @@ +@import "c" diff --git a/test/fixtures/stylus/c.styl b/test/fixtures/stylus/c.styl new file mode 100644 index 0000000..8b13789 --- /dev/null +++ b/test/fixtures/stylus/c.styl @@ -0,0 +1 @@ + diff --git a/test/fixtures/validPartials/a.js b/test/fixtures/validPartials/a.js new file mode 100644 index 0000000..58fd5fb --- /dev/null +++ b/test/fixtures/validPartials/a.js @@ -0,0 +1 @@ +var b = require("./b"); diff --git a/test/fixtures/validPartials/b.js b/test/fixtures/validPartials/b.js new file mode 100644 index 0000000..aef2224 --- /dev/null +++ b/test/fixtures/validPartials/b.js @@ -0,0 +1 @@ +export default 1; diff --git a/test/formats.test.js b/test/formats.test.js index 9b7063c..783799b 100644 --- a/test/formats.test.js +++ b/test/formats.test.js @@ -1,15 +1,8 @@ -import { strict as assert } from 'node:assert'; import path from 'node:path'; -import mockfs from 'mock-fs'; +import { describe, it, expect } from 'vitest'; import Config from '../lib/config.js'; import dependencyTree from '../index.js'; -import { - fixtures, - mockEs6, - mockSass, - mockStylus, - mockLess -} from './helpers.js'; +import { fixtures } from './helpers.js'; function testTreesForFormat(format, ext = '.js') { it('returns an object form of the dependency tree for a file', () => { @@ -19,17 +12,13 @@ function testTreesForFormat(format, ext = '.js') { const tree = dependencyTree({ filename, directory }); const subTree = tree[filename]; - assert.ok(tree instanceof Object); - assert.ok(subTree instanceof Object); - assert.equal(Object.keys(subTree).length, 2); + expect(tree).toBeInstanceOf(Object); + expect(subTree).toBeInstanceOf(Object); + expect(Object.keys(subTree)).toHaveLength(2); }); } describe('module formats', () => { - afterEach(() => { - mockfs.restore(); - }); - describe('amd', () => { testTreesForFormat('amd'); }); @@ -40,13 +29,6 @@ describe('module formats', () => { describe('when given a CJS file with lazy requires', () => { it('includes the lazy dependency', () => { const directory = fixtures('cjs'); - mockfs({ - [directory]: { - 'foo.js': 'module.exports = function(bar = require("./bar")) {};', - 'bar.js': 'module.exports = 1;' - } - }); - const filename = path.normalize(`${directory}/foo.js`); const barPath = path.normalize(`${directory}/bar.js`); @@ -54,26 +36,13 @@ describe('module formats', () => { const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes(barPath), true); + expect(deps).toContain(barPath); }); }); describe('when given a CJS file with module property in package.json', () => { it('includes the module entry as dependency', () => { - const directory = fixtures('es6'); - mockfs({ - [directory]: { - 'module.entry.js': 'import * as module from "module.entry"', - node_modules: { - 'module.entry': { - 'index.main.js': 'module.exports = function() {};', - 'index.module.js': 'module.exports = function() {};', - 'package.json': '{ "main": "index.main.js", "module": "index.module.js" }' - } - } - } - }); - + const directory = fixtures('es6', 'moduleEntry'); const filename = path.normalize(`${directory}/module.entry.js`); const moduleEntryPath = path.normalize(`${directory}/node_modules/module.entry/index.module.js`); @@ -87,16 +56,12 @@ describe('module formats', () => { const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes(moduleEntryPath), true); + expect(deps).toContain(moduleEntryPath); }); }); }); describe('es6', () => { - beforeEach(() => { - mockEs6(); - }); - const directory = fixtures('es6'); testTreesForFormat('es6'); @@ -107,7 +72,7 @@ describe('module formats', () => { const tree = dependencyTree({ filename, directory }); const subTree = tree[filename]; - assert.ok(subTree[path.normalize(`${directory}/c.js`)]); + expect(subTree[path.normalize(`${directory}/c.js`)]).toBeDefined(); }); it('resolves files with a jsx extension', () => { @@ -116,7 +81,7 @@ describe('module formats', () => { const tree = dependencyTree({ filename, directory }); const subTree = tree[filename]; - assert.ok(subTree[path.normalize(`${directory}/b.js`)]); + expect(subTree[path.normalize(`${directory}/b.js`)]).toBeDefined(); }); it('resolves files that have es7', () => { @@ -125,26 +90,18 @@ describe('module formats', () => { const tree = dependencyTree({ filename, directory }); const subTree = tree[filename]; - assert.ok(subTree[path.normalize(`${directory}/c.js`)]); + expect(subTree[path.normalize(`${directory}/c.js`)]).toBeDefined(); }); describe('when given an es6 file using CJS lazy requires', () => { - beforeEach(() => { - mockfs({ - [directory]: { - 'foo.js': 'export default function(bar = require("./bar")) {};', - 'bar.js': 'export default 1;' - } - }); - }); + const lazyDir = fixtures('es6', 'lazyRequires'); + const filename = path.normalize(`${lazyDir}/foo.js`); + const barPath = path.normalize(`${lazyDir}/bar.js`); it('includes the lazy dependency when mixedImports is on', () => { - const filename = path.normalize(`${directory}/foo.js`); - const barPath = path.normalize(`${directory}/bar.js`); - const tree = dependencyTree({ filename, - directory, + directory: lazyDir, detective: { es6: { mixedImports: true @@ -154,16 +111,13 @@ describe('module formats', () => { const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes(barPath), true); + expect(deps).toContain(barPath); }); it('toList includes the lazy dependency when mixedImports is on', () => { - const filename = path.normalize(`${directory}/foo.js`); - const barPath = path.normalize(`${directory}/bar.js`); - const results = dependencyTree.toList({ filename, - directory, + directory: lazyDir, detective: { es6: { mixedImports: true @@ -171,69 +125,49 @@ describe('module formats', () => { } }); - assert.equal(results[0], barPath); - assert.equal(results[1], filename); + expect(results).toStrictEqual([barPath, filename]); }); it('does not include the lazy dependency when mixedImports is off', () => { - const filename = path.normalize(`${directory}/foo.js`); - const barPath = path.normalize(`${directory}/bar.js`); - - const tree = dependencyTree({ filename, directory }); + const tree = dependencyTree({ filename, directory: lazyDir }); const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes(barPath), false); + expect(deps).not.toContain(barPath); }); }); describe('when given an es6 file using dynamic imports', () => { it('includes the dynamic import', () => { - mockfs({ - [directory]: { - 'foo.js': 'import("./bar");', - 'bar.js': 'export default 1;' - } - }); - - const filename = path.normalize(`${directory}/foo.js`); - const barPath = path.normalize(`${directory}/bar.js`); + const dynamicDir = fixtures('es6', 'dynamicImports'); + const filename = path.normalize(`${dynamicDir}/foo.js`); + const barPath = path.normalize(`${dynamicDir}/bar.js`); - const tree = dependencyTree({ filename, directory }); + const tree = dependencyTree({ filename, directory: dynamicDir }); const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes(barPath), true); + expect(deps).toContain(barPath); }); }); }); describe('sass', () => { - beforeEach(() => { - mockSass(); - }); - testTreesForFormat('sass', '.scss'); }); describe('stylus', () => { - beforeEach(() => { - mockStylus(); - }); - testTreesForFormat('stylus', '.styl'); }); describe('less', () => { - beforeEach(() => { - mockLess(); - }); - testTreesForFormat('less', '.less'); }); describe('typescript', () => { const directory = fixtures('ts'); + const depB = path.join(directory, 'b.ts'); + const depC = path.join(directory, 'c.ts'); testTreesForFormat('ts', '.ts'); @@ -247,12 +181,7 @@ describe('module formats', () => { tsConfig: tsConfigPath }); - const depB = path.join(directory, 'b.ts'); - const depC = path.join(directory, 'c.ts'); - - assert.equal(results[0], depB); - assert.equal(results[1], depC); - assert.equal(results[2], filename); + expect(results).toStrictEqual([depB, depC, filename]); }); it('supports tsx files', () => { @@ -261,9 +190,7 @@ describe('module formats', () => { directory }); - const depC = path.join(directory, 'c.ts'); - - assert.equal(results[0], depC); + expect(results[0]).toBe(depC); }); it('excludes type-only imports when skipTypeImports is set', () => { @@ -281,30 +208,33 @@ describe('module formats', () => { const regularDep = path.join(directory, 'c.ts'); const typeOnlyDep = path.join(directory, 'b.ts'); - assert.equal(results.includes(regularDep), true); - assert.equal(results.includes(typeOnlyDep), false); - assert.equal(results.length, 2); + expect(results).toContain(regularDep); + expect(results).not.toContain(typeOnlyDep); + expect(results).toHaveLength(2); }); - it('recognizes ts file import from js file when allowJs is on (#104)', () => { + describe('mixedTsJs', () => { const directory = fixtures('ts', 'mixedTsJs'); - const filename = path.join(directory, 'a.js'); - const tsConfigPath = path.join(directory, '.tsconfig'); - const options = { - filename, - directory, - tsConfig: tsConfigPath - }; - const parsedTsConfig = new Config(options).tsConfig; + it('recognizes ts file import from js file when allowJs is on (#104)', () => { + const filename = path.join(directory, 'a.js'); + const tsConfigPath = path.join(directory, '.tsconfig'); + + const options = { + filename, + directory, + tsConfig: tsConfigPath + }; + const parsedTsConfig = new Config(options).tsConfig; - assert.equal(parsedTsConfig.compilerOptions.allowJs, true); + expect(parsedTsConfig.compilerOptions.allowJs).toBe(true); - const results = dependencyTree.toList(options); + const results = dependencyTree.toList(options); - const depB = path.join(directory, 'b.ts'); + const depB = path.join(directory, 'b.ts'); - assert.equal(results[0], depB); + expect(results[0]).toBe(depB); + }); }); }); }); diff --git a/test/helpers.js b/test/helpers.js index 8306f3a..a00d346 100644 --- a/test/helpers.js +++ b/test/helpers.js @@ -1,64 +1,8 @@ import path from 'node:path'; import { fileURLToPath } from 'node:url'; -import mockfs from 'mock-fs'; export const testDir = path.dirname(fileURLToPath(import.meta.url)); export function fixtures(...parts) { return path.join(testDir, 'fixtures', ...parts); } - -export function mockStylus() { - mockfs({ - [fixtures('stylus')]: { - 'a.styl': ` - @import "b" - @require "c.styl" - `, - 'b.styl': '@import "c"', - 'c.styl': '' - } - }); -} - -export function mockSass() { - mockfs({ - [fixtures('sass')]: { - 'a.scss': ` - @import "_b"; - @import "_c.scss"; - `, - '_b.scss': 'body { color: blue; }', - '_c.scss': 'body { color: pink; }' - } - }); -} - -export function mockLess() { - mockfs({ - [fixtures('less')]: { - 'a.less': ` - @import "b.css"; - @import "c.less"; - `, - 'b.css': 'body { color: blue; }', - 'c.less': 'body { color: pink; }' - } - }); -} - -export function mockEs6() { - mockfs({ - [fixtures('es6')]: { - 'a.js': ` - import b from './b'; - import c from './c'; - `, - 'b.js': 'export default function() {};', - 'c.js': 'export default function() {};', - 'jsx.js': 'import c from "./c";\n export default ;', - 'foo.jsx': 'import React from "react";\n import b from "b";\n export default ;', - 'es7.js': 'import c from "./c";\n export default async function foo() {};' - } - }); -} diff --git a/test/dependency-tree.test.js b/test/index.test.js similarity index 53% rename from test/dependency-tree.test.js rename to test/index.test.js index 1ee2bc0..c1e4a63 100644 --- a/test/dependency-tree.test.js +++ b/test/index.test.js @@ -1,31 +1,25 @@ -import { strict as assert } from 'node:assert'; import path from 'node:path'; import process from 'node:process'; import { createRequire } from 'node:module'; -import mockfs from 'mock-fs'; import precinct from 'precinct'; -import sinon from 'sinon'; +import { + describe, + it, + expect, + vi +} from 'vitest'; import dependencyTree from '../index.js'; import { fixtures } from './helpers.js'; const { resolve } = createRequire(import.meta.url); describe('dependencyTree', () => { - afterEach(() => { - mockfs.restore(); - }); - it('returns an empty object for a non-existent filename', () => { const root = fixtures('imaginary'); - mockfs({ - [root]: {} - }); - const filename = `${root}/notafile.js`; const tree = dependencyTree({ filename, root }); - assert.ok(tree instanceof Object); - assert.equal(Object.keys(tree).length, 0); + expect(tree).toStrictEqual({}); }); it('handles nested tree structures', () => { @@ -37,45 +31,32 @@ describe('dependencyTree', () => { const bTree = subTree[path.normalize(`${directory}/b.js`)]; const cTree = subTree[path.normalize(`${directory}/c.js`)]; - assert.ok(tree instanceof Object); - assert.ok(subTree instanceof Object); - assert.equal(Object.keys(subTree).length, 2); // b and c - assert.equal(Object.keys(bTree).length, 2); // d and e - assert.equal(Object.keys(cTree).length, 2); // f and g + expect(tree).toBeInstanceOf(Object); + expect(subTree).toBeInstanceOf(Object); + expect(Object.keys(subTree)).toHaveLength(2); // b and c + expect(Object.keys(bTree)).toHaveLength(2); // d and e + expect(Object.keys(cTree)).toHaveLength(2); // f and g }); it('does not include files that are not real (#13)', () => { - const directory = fixtures('onlyRealDeps'); - mockfs({ - [directory]: { - 'a.js': 'var notReal = require("./notReal");' - } - }); - + const directory = fixtures('onlyMissingDep'); const filename = path.normalize(`${directory}/a.js`); const tree = dependencyTree({ filename, directory }); const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes('notReal'), false); + expect(deps).not.toContain('notReal'); }); it('does not choke on cyclic dependencies', () => { const directory = fixtures('cyclic'); - mockfs({ - [directory]: { - 'a.js': 'var b = require("./b");', - 'b.js': 'var a = require("./a");' - } - }); - const filename = path.normalize(`${directory}/a.js`); const tree = dependencyTree({ filename, directory }); const deps = Object.keys(tree[filename]); - assert.notEqual(deps.length, 0); + expect(deps.length).toBeGreaterThan(0); }); it('excludes Node.js core modules by default', () => { @@ -86,8 +67,8 @@ describe('dependencyTree', () => { const deps = Object.keys(tree[filename]); const firstKey = Object.keys(tree)[0]; - assert.equal(deps.length, 0); - assert.equal(firstKey.includes('b.js'), true); + expect(deps).toHaveLength(0); + expect(firstKey).toContain('b.js'); }); it('traverses installed 3rd party node modules', () => { @@ -98,7 +79,7 @@ describe('dependencyTree', () => { const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.includes(resolve('debug')), true); + expect(deps).toContain(resolve('debug')); }); it('returns a list of absolutely pathed files', () => { @@ -109,28 +90,18 @@ describe('dependencyTree', () => { for (const node in tree.nodes) { if (Object.hasOwn(tree.nodes, node)) { - assert.equal(node.includes(process.cwd()), true); + expect(node).toContain(process.cwd()); } } }); it('excludes duplicate modules from the tree', () => { - mockfs({ - root: { - // More than one module includes c - 'a.js': `import b from "b"; - import c from "c";`, - 'b.js': 'import c from "c";', - 'c.js': 'export default 1;' - } - }); + const directory = fixtures('duplicateModules'); + const filename = path.normalize(`${directory}/a.js`); - const tree = dependencyTree.toList({ - filename: 'root/a.js', - directory: 'root' - }); + const tree = dependencyTree.toList({ filename, directory }); - assert.equal(tree.length, 3); + expect(tree).toHaveLength(3); }); it('resolves TypeScript imports to their type definition files by default', () => { @@ -141,12 +112,12 @@ describe('dependencyTree', () => { const list = dependencyTree.toList({ filename, directory }); - assert.equal(list.includes(dtsPath), true); - assert.equal(list.includes(jsPath), false); + expect(list).toContain(dtsPath); + expect(list).not.toContain(jsPath); }); it('passes detective config through to precinct', () => { - const spy = sinon.spy(precinct, 'paperwork'); + const spy = vi.spyOn(precinct, 'paperwork'); const directory = fixtures('onlyRealDeps'); const filename = path.normalize(`${directory}/a.js`); const detectiveConfig = { @@ -161,8 +132,8 @@ describe('dependencyTree', () => { detective: detectiveConfig }); - assert.equal(spy.calledWith(filename, detectiveConfig), true); - spy.restore(); + expect(spy).toHaveBeenCalledWith(filename, detectiveConfig); + spy.mockRestore(); }); it('uses the filter to determine if a file should be included in the results', () => { @@ -176,8 +147,8 @@ describe('dependencyTree', () => { filter(filePath, moduleFile) { const normalizedModuleFile = moduleFile.replaceAll('\\', '/'); const expectedPath = path.normalize('test/fixtures/onlyRealDeps/a.js').replaceAll('\\', '/'); - assert.ok(resolve('debug')); - assert.ok(normalizedModuleFile.match(expectedPath)); + expect(resolve('debug')).toBeDefined(); + expect(normalizedModuleFile).toMatch(expectedPath); return !filePath.includes('node_modules'); } }); @@ -186,144 +157,107 @@ describe('dependencyTree', () => { const deps = Object.keys(subTree); const treeKeys = Object.keys(tree); - assert.notEqual(treeKeys.length, 0); - assert.equal(deps.includes(resolve('debug')), false); + expect(treeKeys.length).toBeGreaterThan(0); + expect(deps).not.toContain(resolve('debug')); }); - it('stores invalid partials in the nonExistent list', () => { - const directory = fixtures('onlyRealDeps'); - mockfs({ - [directory]: { - 'a.js': 'var notReal = require("./notReal");' - } - }); - - const filename = path.normalize(`${directory}/a.js`); - const nonExistent = []; - - dependencyTree({ filename, directory, nonExistent }); + describe('nonExistent option', () => { + it('stores invalid partials in the nonExistent list', () => { + const directory = fixtures('onlyMissingDep'); + const filename = path.normalize(`${directory}/a.js`); + const nonExistent = []; - assert.equal(nonExistent.length, 1); - assert.equal(nonExistent[0], './notReal'); - }); + dependencyTree({ filename, directory, nonExistent }); - it('does not add valid partials to the nonExistent list', () => { - const directory = fixtures('onlyRealDeps'); - mockfs({ - [directory]: { - 'a.js': 'var b = require("./b");', - 'b.js': 'export default 1;' - } + expect(nonExistent).toStrictEqual(['./notReal']); }); - const filename = path.normalize(`${directory}/a.js`); - const nonExistent = []; + it('does not add valid partials to the nonExistent list', () => { + const directory = fixtures('validPartials'); + const filename = path.normalize(`${directory}/a.js`); + const nonExistent = []; - dependencyTree({ filename, directory, nonExistent }); + dependencyTree({ filename, directory, nonExistent }); - assert.equal(nonExistent.length, 0); - }); - - it('stores only invalid partials when there is a mix of valid and invalid', () => { - const directory = fixtures('onlyRealDeps'); - mockfs({ - [directory]: { - 'a.js': 'var b = require("./b");', - 'b.js': 'var c = require("./c"); export default 1;', - 'c.js': 'var crap = require("./notRealMan");' - } + expect(nonExistent).toStrictEqual([]); }); - const filename = path.normalize(`${directory}/a.js`); - const nonExistent = []; - - dependencyTree({ filename, directory, nonExistent }); + it('stores only invalid partials when there is a mix of valid and invalid', () => { + const directory = fixtures('mixedPartials'); + const filename = path.normalize(`${directory}/a.js`); + const nonExistent = []; - assert.equal(nonExistent.length, 1); - assert.equal(nonExistent[0], './notRealMan'); - }); + dependencyTree({ filename, directory, nonExistent }); - it('only includes a non-existent partial once when referenced multiple times', () => { - const directory = fixtures('onlyRealDeps'); - mockfs({ - [directory]: { - 'a.js': 'var b = require("./b");\nvar crap = require("./notRealMan");', - 'b.js': 'var c = require("./c"); export default 1;', - 'c.js': 'var crap = require("./notRealMan");' - } + expect(nonExistent).toStrictEqual(['./notRealMan']); }); - const filename = path.normalize(`${directory}/a.js`); - const nonExistent = []; - - dependencyTree({ filename, directory, nonExistent }); + it('only includes a non-existent partial once when referenced multiple times', () => { + const directory = fixtures('repeatedMissing'); + const filename = path.normalize(`${directory}/a.js`); + const nonExistent = []; - assert.equal(nonExistent.length, 1); - assert.equal(nonExistent[0], './notRealMan'); - }); + dependencyTree({ filename, directory, nonExistent }); - it('stores a Sass partial in nonExistent when the resolved path does not exist on disk', () => { - const directory = fixtures('sass'); - mockfs({ - [directory]: { - 'a.scss': '@import "missing-partial";' - } + expect(nonExistent).toStrictEqual(['./notRealMan']); }); - const filename = path.normalize(`${directory}/a.scss`); - const nonExistent = []; + it('stores a Sass partial in nonExistent when the resolved path does not exist on disk', () => { + const directory = fixtures('missingSassPartial'); + const filename = path.normalize(`${directory}/a.scss`); + const nonExistent = []; - dependencyTree({ filename, directory, nonExistent }); + dependencyTree({ filename, directory, nonExistent }); - assert.equal(nonExistent.length, 1); - assert.equal(nonExistent[0], 'missing-partial'); + expect(nonExistent).toStrictEqual(['missing-partial']); + }); }); describe('throws', () => { it('throws if the filename is missing', () => { - assert.throws(() => { + expect(() => { dependencyTree({ filename: undefined, directory: fixtures('commonjs') }); - }, /^Error: filename not given$/); + }).toThrow(new Error('filename not given')); }); it('throws if the root is missing', () => { - assert.throws(() => { + expect(() => { dependencyTree({ undefined }); - }, /^Error: filename not given$/); + }).toThrow(new Error('filename not given')); }); it('throws if the directory is missing', () => { - assert.throws(() => { + expect(() => { dependencyTree({ filename: 'foo.js', directory: undefined }); - }, /^Error: directory not given$/); + }).toThrow(new Error('directory not given')); }); it('throws if a supplied filter is not a function', () => { const directory = fixtures('onlyRealDeps'); const filename = path.normalize(`${directory}/a.js`); - assert.throws(() => { + expect(() => { dependencyTree({ filename, directory, filter: 'foobar' }); - }, /^Error: filter must be a function$/); + }).toThrow(new Error('filter must be a function')); }); it('does not throw on the legacy `root` option', () => { - assert.doesNotThrow(() => { - const directory = fixtures('onlyRealDeps'); - const filename = path.normalize(`${directory}/a.js`); + const directory = fixtures('onlyRealDeps'); + const filename = path.normalize(`${directory}/a.js`); + expect(() => { dependencyTree({ filename, root: directory }); - }); + }).not.toThrow(); }); }); @@ -331,31 +265,34 @@ describe('dependencyTree', () => { const directory = fixtures('commonjs'); it('does not throw', () => { - assert.doesNotThrow(() => { + expect(() => { dependencyTree({ filename: 'foo', directory }); - }); + }).not.toThrow(); }); it('returns no dependencies', () => { const tree = dependencyTree({ filename: 'foo', directory }); - assert.equal(Object.keys(tree).length, 0); + expect(tree).toStrictEqual({}); }); it('returns empty tree when precinct throws', () => { - const stub = sinon.stub(precinct, 'paperwork').throws(new Error('parse error')); + const stub = vi.spyOn(precinct, 'paperwork').mockImplementation(() => { + throw new Error('parse error'); + }); const filename = path.join(directory, 'a.js'); const tree = dependencyTree({ filename, directory }); - assert.deepEqual(tree[filename], {}); - stub.restore(); + expect(tree[filename]).toStrictEqual({}); + stub.mockRestore(); }); }); describe('memoization (#2)', () => { + const directory = fixtures('amd'); + const filename = path.join(directory, 'a.js'); + it('accepts a cache object for memoization (#2)', () => { - const directory = fixtures('amd'); - const filename = path.join(directory, 'a.js'); const bFile = path.join(directory, 'b.js'); const cFile = path.join(directory, 'c.js'); const cache = { @@ -369,13 +306,10 @@ describe('dependencyTree', () => { }); const deps = Object.keys(tree[filename]); - assert.equal(deps.length, 2); + expect(deps).toHaveLength(2); }); it('returns the precomputed list of a cached entry point', () => { - const directory = fixtures('amd'); - const filename = path.join(directory, 'a.js'); - const cache = { [filename]: [] // Shouldn't process the first file's tree }; @@ -386,101 +320,54 @@ describe('dependencyTree', () => { visited: cache }); - assert.deepEqual(tree[filename], []); + expect(tree[filename]).toStrictEqual([]); }); }); describe('getLocalConfigDirectory', () => { it('resolves sub-dependencies of a file whose name contains "node_modules" but whose directory does not', () => { const directory = fixtures('nodeModulesInName'); - mockfs({ - [directory]: { - 'a.js': 'var x = require("./node_modules.helper");', - 'node_modules.helper.js': 'var y = require("./sub");', - 'sub.js': 'export default 1;' - } - }); - const filename = path.join(directory, 'a.js'); const helperPath = path.join(directory, 'node_modules.helper.js'); const subPath = path.join(directory, 'sub.js'); const list = dependencyTree.toList({ filename, directory }); - assert.equal(list.includes(helperPath), true); - assert.equal(list.includes(subPath), true); + expect(list).toContain(helperPath); + expect(list).toContain(subPath); }); it('resolves the correct root directory for a scoped package in node_modules', () => { const directory = fixtures('scopedPackage'); - mockfs({ - [directory]: { - 'a.js': 'var x = require("./node_modules/@scope/pkg/index");', - node_modules: { - '@scope': { - pkg: { - 'index.js': 'var y = require("./util");', - 'util.js': 'export default 1;' - } - } - } - } - }); - const filename = path.join(directory, 'a.js'); const indexPath = path.join(directory, 'node_modules', '@scope', 'pkg', 'index.js'); const utilPath = path.join(directory, 'node_modules', '@scope', 'pkg', 'util.js'); const list = dependencyTree.toList({ filename, directory }); - assert.equal(list.includes(indexPath), true); - assert.equal(list.includes(utilPath), true); + expect(list).toContain(indexPath); + expect(list).toContain(utilPath); }); it('resolves sub-dependencies for a package inside nested node_modules', () => { const directory = fixtures('nestedNodeModules'); - mockfs({ - [directory]: { - 'a.js': 'var x = require("./node_modules/pkg-a/index");', - node_modules: { - 'pkg-a': { - 'index.js': 'var y = require("./node_modules/pkg-b/index");', - node_modules: { - 'pkg-b': { - 'index.js': 'export default 1;' - } - } - } - } - } - }); - const filename = path.join(directory, 'a.js'); const pkgAPath = path.join(directory, 'node_modules', 'pkg-a', 'index.js'); const pkgBPath = path.join(directory, 'node_modules', 'pkg-a', 'node_modules', 'pkg-b', 'index.js'); const list = dependencyTree.toList({ filename, directory }); - assert.equal(list.includes(pkgAPath), true); - assert.equal(list.includes(pkgBPath), true); + expect(list).toContain(pkgAPath); + expect(list).toContain(pkgBPath); }); it('does not throw when a file sits directly inside node_modules/ without a package subfolder', () => { const directory = fixtures('directNodeModules'); - mockfs({ - [directory]: { - 'a.js': 'var x = require("./node_modules/direct");', - node_modules: { - 'direct.js': 'export default 1;' - } - } - }); - const filename = path.join(directory, 'a.js'); - assert.doesNotThrow(() => { + expect(() => { dependencyTree.toList({ filename, directory }); - }); + }).not.toThrow(); }); }); }); diff --git a/test/node-modules.test.js b/test/node-modules.test.js index 0c04593..9f39ccd 100644 --- a/test/node-modules.test.js +++ b/test/node-modules.test.js @@ -1,128 +1,56 @@ -import { strict as assert } from 'node:assert'; import path from 'node:path'; -import mockfs from 'mock-fs'; +import { describe, it, expect } from 'vitest'; import dependencyTree from '../index.js'; import { fixtures } from './helpers.js'; describe('package-specific node_modules resolution', () => { - afterEach(() => { - mockfs.restore(); - }); - - it('finds sub package in node module package', () => { - const directory = fixtures('es6'); - mockfs({ - [directory]: { - 'module.entry.js': 'import * as module from "parent_module_a"', - node_modules: { - parent_module_a: { - 'index.main.js': 'import * as child_module from "child_node_module"; module.exports = child_module;', - 'package.json': '{ "main": "index.main.js"}', - node_modules: { - child_node_module: { - 'index.main.js': 'module.exports = "child_node_module_of_parent_a"', - 'package.json': '{ "main": "index.main.js"}' - } - } - } - } - } - }); - + describe('with a nested parent/child package layout', () => { + const directory = fixtures('es6', 'parentChild'); const filename = path.normalize(`${directory}/module.entry.js`); - const childPath = path.normalize(`${directory}/node_modules/parent_module_a/node_modules/child_node_module/index.main.js`); - - const treeList = dependencyTree({ - filename, - directory, - isListForm: true - }); + const rootChildPath = path.normalize(`${directory}/node_modules/child_node_module/index.main.js`); + const nestedChildPath = path.normalize(`${directory}/node_modules/parent_module_a/node_modules/child_node_module/index.main.js`); - assert.equal(treeList.includes(childPath), true); - }); + it('finds sub package in node module package', () => { + const treeList = dependencyTree({ + filename, + directory, + isListForm: true + }); - it('uses correct version of sub package in node module package', () => { - const directory = fixtures('es6'); - mockfs({ - [directory]: { - 'module.entry.js': 'import * as module from "parent_module_a"', - node_modules: { - child_node_module: { - 'index.main.js': 'module.exports = "child_node_module"', - 'package.json': '{ "main": "index.main.js", "version": "2.0.0"}' - }, - parent_module_a: { - 'index.main.js': 'import * as child_module from "child_node_module"; module.exports = child_module;', - 'package.json': '{ "main": "index.main.js"}', - node_modules: { - child_node_module: { - 'index.main.js': 'module.exports = "child_node_module_of_parent_a"', - 'package.json': '{ "main": "index.main.js", "version": "1.0.0"}' - } - } - } - } - } + expect(treeList).toContain(nestedChildPath); }); - const filename = path.normalize(`${directory}/module.entry.js`); - const rootChildPath = path.normalize(`${directory}/node_modules/child_node_module/index.main.js`); - const nestedChildPath = path.normalize(`${directory}/node_modules/parent_module_a/node_modules/child_node_module/index.main.js`); + it('uses correct version of sub package in node module package', () => { + const treeList = dependencyTree({ + filename, + directory, + isListForm: true + }); - const treeList = dependencyTree({ - filename, - directory, - isListForm: true + expect(treeList).not.toContain(rootChildPath); + expect(treeList).toContain(nestedChildPath); }); - - assert.equal(treeList.includes(rootChildPath), false); - assert.equal(treeList.includes(nestedChildPath), true); }); it('falls back to entry directory when a node_modules file has no package subpath', () => { const baseDir = fixtures('flat-nm'); - - mockfs({ - [baseDir]: { - 'a.js': 'var x = require("flatmod");', - node_modules: { - 'flatmod.js': 'module.exports = 1;' - } - } - }); - const filename = path.normalize(`${baseDir}/a.js`); const tree = dependencyTree({ filename, directory: baseDir }); const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.some(dep => dep.includes('flatmod')), true); + expect(deps.some(dep => dep.includes('flatmod'))).toBe(true); }); it('resolves the project path for a scoped node_modules package', () => { const baseDir = fixtures('scoped-nm'); - - mockfs({ - [baseDir]: { - 'a.js': 'var x = require("@scope/pkg");', - node_modules: { - '@scope': { - pkg: { - 'index.js': 'module.exports = 1;', - 'package.json': '{ "main": "index.js" }' - } - } - } - } - }); - const filename = path.normalize(`${baseDir}/a.js`); const tree = dependencyTree({ filename, directory: baseDir }); const subTree = tree[filename]; const deps = Object.keys(subTree); - assert.equal(deps.some(dep => dep.includes(path.join('@scope', 'pkg'))), true); + expect(deps.some(dep => dep.includes(path.join('@scope', 'pkg')))).toBe(true); }); }); diff --git a/test/resolvers.test.js b/test/resolvers.test.js index 6e106d4..e159a96 100644 --- a/test/resolvers.test.js +++ b/test/resolvers.test.js @@ -1,15 +1,14 @@ -import { strict as assert } from 'node:assert'; import path from 'node:path'; import process from 'node:process'; -import mockfs from 'mock-fs'; +import { describe, it, expect } from 'vitest'; import dependencyTree from '../index.js'; import { fixtures, testDir } from './helpers.js'; function assertResolvesToLodizzle(tree, entryFile) { const filename = path.resolve(process.cwd(), entryFile); - const aliasedFile = path.resolve(process.cwd(), 'root/lodizzle.js').replaceAll('\\', '/'); + const aliasedFile = path.resolve(process.cwd(), entryFile, '..', 'lodizzle.js').replaceAll('\\', '/'); const normalizedTreeFilename = Object.keys(tree[filename]).map(f => f.replaceAll('\\', '/')); - assert.equal(aliasedFile.includes(normalizedTreeFilename), true); + expect(aliasedFile.includes(normalizedTreeFilename)).toBe(true); } describe('webpack', () => { @@ -27,7 +26,7 @@ describe('webpack', () => { filter: filename => filename.includes('filing-cabinet') }); - assert.equal(results.some(filename => filename.includes(filingCabinetPath)), true); + expect(results.some(filename => filename.includes(filingCabinetPath))).toBe(true); }); it('resolves unaliased modules', () => { @@ -38,7 +37,7 @@ describe('webpack', () => { filter: filename => filename.includes('filing-cabinet') }); - assert.equal(results.some(filename => filename.includes(filingCabinetPath)), true); + expect(results.some(filename => filename.includes(filingCabinetPath))).toBe(true); }); it('resolves @ prefixed aliases with absolute path values', () => { @@ -51,50 +50,16 @@ describe('webpack', () => { filter: filename => filename.includes(path.join('webpack', 'src')) }); - assert.equal(results.some(filename => filename.includes(atAliasedSrcPath)), true); + expect(results.some(filename => filename.includes(atAliasedSrcPath))).toBe(true); }); }); describe('requirejs', () => { - const directory = 'root'; - const requireConfig = 'root/require.config.js'; - - beforeEach(() => { - mockfs({ - [directory]: { - 'lodizzle.js': 'define({})', - 'require.config.js': ` - requirejs.config({ - baseUrl: './', - paths: { - F: './lodizzle.js' - } - }); - `, - 'a.js': ` - define([ - 'F' - ], function(F) { - - }); - `, - 'b.js': ` - define([ - './lodizzle' - ], function(F) { - - }); - ` - } - }); - }); - - afterEach(() => { - mockfs.restore(); - }); + const directory = fixtures('requirejs', 'root'); + const requireConfig = path.join(directory, 'require.config.js'); it('resolves aliased modules', () => { - const filename = 'root/a.js'; + const filename = path.join(directory, 'a.js'); const tree = dependencyTree({ filename, @@ -106,7 +71,7 @@ describe('requirejs', () => { }); it('resolves non-aliased paths', () => { - const filename = 'root/b.js'; + const filename = path.join(directory, 'b.js'); const tree = dependencyTree({ filename, @@ -118,29 +83,17 @@ describe('requirejs', () => { }); it('adds to nonExistent when the alias resolves to a path that does not exist on disk', () => { - mockfs({ - [directory]: { - 'a.js': 'define(["phantom"], function(p) {});', - 'require.config.js': ` - requirejs.config({ - baseUrl: './', - paths: { - phantom: './phantom-module' - } - }); - ` - } - }); - + const phantomDir = fixtures('requirejs', 'phantom'); + const phantomConfig = path.join(phantomDir, 'require.config.js'); const nonExistent = []; dependencyTree({ - filename: 'root/a.js', - directory, - config: requireConfig, + filename: path.join(phantomDir, 'a.js'), + directory: phantomDir, + config: phantomConfig, nonExistent }); - assert.equal(nonExistent.includes('phantom'), true); + expect(nonExistent).toContain('phantom'); }); }); diff --git a/test/to-list.test.js b/test/to-list.test.js index 7363c93..cd3a989 100644 --- a/test/to-list.test.js +++ b/test/to-list.test.js @@ -1,14 +1,7 @@ -import { strict as assert } from 'node:assert'; import path from 'node:path'; -import mockfs from 'mock-fs'; +import { describe, it, expect } from 'vitest'; import dependencyTree from '../index.js'; -import { - fixtures, - mockEs6, - mockSass, - mockStylus, - mockLess -} from './helpers.js'; +import { fixtures } from './helpers.js'; function testToList(format, ext = '.js') { it('returns a post-order list form of the dependency tree', () => { @@ -16,27 +9,18 @@ function testToList(format, ext = '.js') { const filename = path.normalize(`${directory}/a${ext}`); const list = dependencyTree.toList({ filename, directory }); - assert.equal(Array.isArray(list), true); - assert.notEqual(list.length, 0); + expect(list).toBeInstanceOf(Array); + expect(list.length).toBeGreaterThan(0); }); } describe('toList', () => { - afterEach(() => { - mockfs.restore(); - }); - it('returns an empty list on a non-existent filename', () => { const directory = fixtures('imaginary'); - mockfs({ - [directory]: {} - }); - const filename = path.normalize(`${directory}/notafile.js`); const list = dependencyTree.toList({ filename, directory }); - assert.equal(Array.isArray(list), true); - assert.equal(list.length, 0); + expect(list).toStrictEqual([]); }); it('orders the visited files by last visited', () => { @@ -44,10 +28,11 @@ describe('toList', () => { const filename = path.normalize(`${directory}/a.js`); const list = dependencyTree.toList({ filename, directory }); - assert.equal(list.length, 3); - assert.equal(path.normalize(list[0]), path.normalize(`${directory}/c.js`)); - assert.equal(path.normalize(list[1]), path.normalize(`${directory}/b.js`)); - assert.equal(list.at(-1), filename); + expect(list.map(p => path.normalize(p))).toStrictEqual([ + path.normalize(`${directory}/c.js`), + path.normalize(`${directory}/b.js`), + filename + ]); }); describe('module formats', () => { @@ -60,34 +45,18 @@ describe('toList', () => { }); describe('es6', () => { - beforeEach(() => { - mockEs6(); - }); - testToList('es6'); }); describe('sass', () => { - beforeEach(() => { - mockSass(); - }); - testToList('sass', '.scss'); }); describe('stylus', () => { - beforeEach(() => { - mockStylus(); - }); - testToList('stylus', '.styl'); }); describe('less', () => { - beforeEach(() => { - mockLess(); - }); - testToList('less', '.less'); }); diff --git a/vitest.config.js b/vitest.config.js new file mode 100644 index 0000000..f3cb229 --- /dev/null +++ b/vitest.config.js @@ -0,0 +1,12 @@ +import { defineConfig } from 'vitest/config'; + +export default defineConfig({ + test: { + include: ['test/**/*.test.js'], + coverage: { + provider: 'v8', + reporter: ['html', 'lcovonly', 'text'], + exclude: ['test/**'] + } + } +}); diff --git a/xo.config.js b/xo.config.js index 94fb6a0..6eacacb 100644 --- a/xo.config.js +++ b/xo.config.js @@ -1,5 +1,3 @@ -import globals from 'globals'; - export default [ { ignores: [ @@ -50,13 +48,5 @@ export default [ 'unicorn/prefer-top-level-await': 'off', 'unicorn/prevent-abbreviations': 'off' } - }, - { - files: [ - 'test/**/*.js' - ], - languageOptions: { - globals: globals.mocha - } } ];