MCPcopy Create free account
hub / github.com/Effect-TS/effect / project

Function project

vitest.config.ts:14–39  ·  view source on GitHub ↗
(
  name: string,
  directory: string,
  include: boolean = true,
  config: ViteUserConfig = {},
  projectExclude?: ReadonlyArray<string>,
  projectInclude?: ReadonlyArray<string>
)

Source from the content-addressed store, hash-verified

12const clusterTestsEnabled = process.env.EFFECT_CLUSTER_TESTS === "1"
13
14const project = (
15 name: string,
16 directory: string,
17 include: boolean = true,
18 config: ViteUserConfig = {},
19 projectExclude?: ReadonlyArray<string>,
20 projectInclude?: ReadonlyArray<string>
21) => {
22 if (!include) {
23 return []
24 }
25
26 const cfg = mergeConfig({
27 root: directory,
28 test: { name }
29 }, config)
30
31 const merged = mergeConfig(shared, cfg)
32 if (projectExclude !== undefined) {
33 merged.test!.exclude = [...projectExclude]
34 }
35 if (projectInclude !== undefined) {
36 merged.test!.include = [...projectInclude]
37 }
38 return [merged]
39}
40
41export const exclude = [
42 "**/.*/**",

Callers 1

vitest.config.tsFile · 0.85

Calls 1

mergeConfigFunction · 0.90

Tested by

no test coverage detected