-
-
Notifications
You must be signed in to change notification settings - Fork 372
Expand file tree
/
Copy pathvitest.config.ts
More file actions
53 lines (51 loc) · 1.48 KB
/
vitest.config.ts
File metadata and controls
53 lines (51 loc) · 1.48 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
42
43
44
45
46
47
48
49
50
51
52
53
import { defineConfig } from "vitest/config";
import path from "node:path";
import { fileURLToPath } from "node:url";
const __dirname = path.dirname(fileURLToPath(import.meta.url));
export default defineConfig({
resolve: {
alias: [
// @silverbulletmd/silverbullet/* → local plug-api/ files
{
find: /^@silverbulletmd\/silverbullet\/lib\/(.*)$/,
replacement: path.resolve(__dirname, "plug-api/lib/$1.ts"),
},
{
find: /^@silverbulletmd\/silverbullet\/type\/(.*)$/,
replacement: path.resolve(__dirname, "plug-api/types/$1.ts"),
},
{
find: "@silverbulletmd/silverbullet/syscall",
replacement: path.resolve(__dirname, "plug-api/syscall.ts"),
},
{
find: "@silverbulletmd/silverbullet/syscalls",
replacement: path.resolve(__dirname, "plug-api/syscalls.ts"),
},
{
find: "@silverbulletmd/silverbullet/constants",
replacement: path.resolve(__dirname, "plug-api/constants.ts"),
},
// fuse → fuse.js
{
find: "fuse",
replacement: "fuse.js",
},
],
},
test: {
include: ["**/*.test.ts"],
exclude: [
"**/node_modules/**",
"**/.opencode/**",
"dist",
"client_bundle",
"e2e",
"website",
"server",
// Exclude helper test files (no test() blocks, only export helper functions)
"client/data/kv_primitives.test.ts",
"client/spaces/space_primitives.test.ts",
],
},
});