Skip to content

Commit 1cd00c9

Browse files
authored
test: migrate from jest to vitest (#861)
1 parent dbc3277 commit 1cd00c9

File tree

11 files changed

+3616
-9275
lines changed

11 files changed

+3616
-9275
lines changed

babel.config.json

Lines changed: 0 additions & 30 deletions
This file was deleted.

eslint.config.mjs

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,17 @@
33
import eslint from '@eslint/js';
44
import globals from 'globals';
55
import prettier from 'eslint-config-prettier';
6-
import jest from 'eslint-plugin-jest';
6+
import vitest from '@vitest/eslint-plugin';
77
import react from 'eslint-plugin-react';
88
import reactHooks from 'eslint-plugin-react-hooks';
99
import reactHooksAddons from 'eslint-plugin-react-hooks-addons';
1010

1111
export default [
1212
eslint.configs.recommended,
1313
prettier,
14-
jest.configs['flat/recommended'],
15-
jest.configs['flat/style'],
14+
vitest.configs.recommended,
1615
react.configs.flat.recommended,
16+
react.configs.flat['jsx-runtime'],
1717
reactHooksAddons.configs.recommended,
1818
{
1919
ignores: ['**/dist/', '**/types/', '**/coverage/', '**/build/']
@@ -30,7 +30,7 @@ export default [
3030
globals: {
3131
...globals.browser,
3232
...globals.node,
33-
...globals.jest
33+
...globals.vitest
3434
}
3535
},
3636
settings: {
@@ -39,17 +39,13 @@ export default [
3939
}
4040
},
4141
plugins: {
42-
jest,
43-
react,
4442
'react-hooks': reactHooks
4543
},
4644
rules: {
4745
'no-console': ['error', { allow: ['warn', 'error'] }],
48-
'react/react-in-jsx-scope': 0,
4946
'react/prop-types': 0,
5047
'react-hooks/rules-of-hooks': 'error',
51-
'react-hooks/exhaustive-deps': 'error',
52-
'react-hooks-addons/no-unused-deps': 'error'
48+
'react-hooks/exhaustive-deps': 'error'
5349
}
5450
}
5551
];

jest.config.js

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)