Skip to content

Commit

Permalink
Create libs/test-utils-vitest (#5703)
Browse files Browse the repository at this point in the history
* Create libs/test-utils-vitest

Copies all files from libs/test-utils that rely on `jest` and migrate them to use `vitest` instead. This will enable any packages that currently use libs/test-utils to be migrated to vitest by using the vitest version of these utils. Eventually, when we're done migrating and there are no more jest tests, we can move these back into libs/test-utils, replacing the jest versions.

* Regenerate CircleCI config
  • Loading branch information
jonahkagan authored and eventualbuddha committed Dec 11, 2024
1 parent 8af4cd0 commit 8cc2151
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 2 deletions.
2 changes: 1 addition & 1 deletion libs/test-utils-vitest/.eslintignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
build
coverage
vitest.config.mts
vitest.config.mts
2 changes: 1 addition & 1 deletion libs/test-utils-vitest/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ export * from './child_process.js';
export * from './console.js';
export * from './mock_kiosk.js';
export * from './mock_of.js';
export * from './mock_use_audio_controls.js';
export * from './mock_use_audio_controls.js';
21 changes: 21 additions & 0 deletions libs/test-utils-vitest/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import { defineConfig } from 'vitest/config';

export default defineConfig({
test: {
coverage: {
thresholds: {
lines: 84,
branches: 79,
},
provider: 'istanbul',
include: ['src/**/*.ts'],
exclude: [
'src/**/*.test.ts',
'src/advance_timers.ts',
'src/mock_of.ts',
'src/mock_kiosk.ts',
'src/mock_use_audio_controls.ts',
],
},
},
});

0 comments on commit 8cc2151

Please sign in to comment.