Skip to content

Commit

Permalink
test: vitest monorepo
Browse files Browse the repository at this point in the history
  • Loading branch information
p-m-p committed Apr 13, 2024
1 parent 7677dab commit 2911901
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
4 changes: 4 additions & 0 deletions packages/components/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import { defineProject, mergeConfig } from 'vitest/config'
import rootConfig from '../../vitest.root'

export default mergeConfig(rootConfig, defineProject({}))
3 changes: 2 additions & 1 deletion vitest.config.ts → vitest.root.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { join } from 'path'
import { defineConfig } from 'vitest/config'

export default defineConfig({
Expand All @@ -7,6 +8,6 @@ export default defineConfig({
},
environment: 'jsdom',
globals: true,
setupFiles: ['testSetup.ts'],
setupFiles: [join(import.meta.dirname, 'testSetup.ts')],
},
})
1 change: 1 addition & 0 deletions vitest.workspace.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default ['packages/*']

0 comments on commit 2911901

Please sign in to comment.