generated from freeCodeCamp/template
-
-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathvitest.integration.config.mjs
More file actions
27 lines (25 loc) · 834 Bytes
/
vitest.integration.config.mjs
File metadata and controls
27 lines (25 loc) · 834 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
import { configDefaults, defineConfig } from "vitest/config";
const integrationTests = [
"./packages/tests/integration-tests/index.test.ts",
"./packages/tests/integration-tests/timeout.test.ts",
];
export default defineConfig({
test: {
watchTriggerPatterns: [
{
pattern: /packages\/.*\/.*\.ts$/,
testsToRun: () => {
// Any source change could impact the integration tests
return integrationTests;
},
},
],
name: "integration",
globals: true, // TODO: remove this OR include vitest types
environment: "puppeteer",
include: integrationTests,
exclude: [...configDefaults.exclude, "packages/*/build", "dist"],
globalSetup: "vitest-environment-puppeteer/global-init",
setupFiles: ["./packages/shared/tooling/webpack-compile.ts"],
},
});