forked from defi-wonderland/aztec-fee-payment
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvitest.config.ts
More file actions
41 lines (39 loc) · 1.14 KB
/
vitest.config.ts
File metadata and controls
41 lines (39 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import { defineConfig } from "vitest/config";
import { fileURLToPath } from "node:url";
import { dirname, resolve as pathResolve } from "node:path";
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
const nobleUtilsPath = pathResolve(
__dirname,
"node_modules/@noble/hashes/esm/utils.js",
);
export default defineConfig({
resolve: {
alias: {
// Force a concrete file path so CI doesn't resolve a nested version without `anumber`
"@noble/hashes/utils": nobleUtilsPath,
},
conditions: ["import", "module", "browser", "default"],
},
test: {
// aztec local network tests take quite some time
hookTimeout: 200000,
testTimeout: 200000,
fileParallelism: false,
pool: "forks",
poolOptions: {
forks: {
singleFork: true,
isolate: false,
execArgv: ["--experimental-vm-modules"],
},
},
include: ["src/ts/test/**/*.test.ts"],
// Use new API to inline dependencies through Vite's transform pipeline
server: {
deps: {
inline: [/@aztec/, /@noble\/(hashes|curves|ciphers)/, /viem/, /@scure/],
},
},
},
});