-
Notifications
You must be signed in to change notification settings - Fork 102
Expand file tree
/
Copy pathvitest.shared.ts
More file actions
38 lines (36 loc) · 997 Bytes
/
Copy pathvitest.shared.ts
File metadata and controls
38 lines (36 loc) · 997 Bytes
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
import path from 'path';
import { defineConfig } from 'vitest/config';
const __dirname = import.meta.dirname;
export default defineConfig( {
test: {
pool: 'threads',
globals: true,
// Registered test tags for selective runs, e.g. `npm test -- --tagsFilter='e2e'`
// or excluding the slow real-CLI tests with `--tagsFilter='!e2e'`.
tags: [
{
name: 'e2e',
description:
'Real end-to-end tests that spawn the built CLI and create real sites. Require `npm run cli:build` first; run in the slower (release/manual) suite, not per-PR.',
},
],
environment: 'jsdom',
environmentOptions: {
customExportConditions: [ 'node', 'node-addons' ],
},
exclude: [
'**/node_modules/**',
'**/tests/utils/**',
'**/stores/tests/utils/**',
'**/vendor/**',
],
globalSetup: path.resolve( __dirname, './vitest.global-setup.ts' ),
server: {
deps: {
inline: [ '@php-wasm', '@wp-playground' ],
external: [ 'electron' ],
},
},
css: false,
},
} );