Spaces:
Running
Running
Download vitest.config.js from RemiFabre/morse-code: direct link, hf CLI and curl.
- Browser
- Download file 632 Bytes
-
https://huggingface.co/spaces/RemiFabre/morse-code/resolve/main/vitest.config.js
- Command line
-
hf download hf://spaces/RemiFabre/morse-code/vitest.config.js
-
curl -L -o vitest.config.js https://huggingface.co/spaces/RemiFabre/morse-code/resolve/main/vitest.config.js
632 Bytes
| import { defineConfig } from "vitest/config"; | |
| import { fileURLToPath } from "node:url"; | |
| // Stub the SDK animation wrapper in unit tests: Node's ESM loader can't | |
| // resolve `https:` imports, and the unit suite never touches the live SDK. | |
| // Production loads the real wrapper from jsDelivr. | |
| const animationStub = fileURLToPath( | |
| new URL("./tests/stubs/animation-helpers.js", import.meta.url), | |
| ); | |
| export default defineConfig({ | |
| test: { | |
| include: ["tests/unit/**/*.test.js"], | |
| environment: "node", | |
| globals: false, | |
| alias: { | |
| "./animation-helpers.js": animationStub, | |
| }, | |
| }, | |
| }); | |