Skip to content

Commit 0ede538

Browse files
authored
Merge pull request #41 from Adrianmjim/chore/migrate-vitest
chore(test): Migrate to vitest
2 parents 07e3f09 + 81842a8 commit 0ede538

22 files changed

+976
-2534
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -116,10 +116,7 @@ jobs:
116116
run: pnpm install
117117

118118
- name: Check Tests
119-
run: pnpm test:js:coverage
120-
121-
- name: Build
122-
run: pnpm build
119+
run: pnpm test:coverage
123120

124121
- name: Upload coverage to Codecov
125122
uses: codecov/codecov-action@v4

.github/workflows/codecov_test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
run: pnpm build
3636

3737
- name: Check Tests
38-
run: pnpm test:js:coverage
38+
run: pnpm test:coverage
3939

4040
- name: Upload coverage to Codecov
4141
uses: codecov/codecov-action@v4

config/getJestJsProjectConfig.js

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

config/getJestProjectConfig.js

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

config/getJestTsProjectConfig.js

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

config/getTestMatch.js

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

config/jestConfig.js

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

config/projectRoot.js

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

eslint.config.mjs

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import js from '@eslint/js';
22
import tsEslint from 'typescript-eslint';
33
import tsEslintParser from '@typescript-eslint/parser';
4-
//import vitest from 'eslint-plugin-vitest';
4+
import vitest from 'eslint-plugin-vitest';
55
import eslintImport from 'eslint-plugin-import';
66
import { fixupPluginRules } from '@eslint/compat';
77

@@ -196,25 +196,25 @@ export default tsEslint.config(
196196
},
197197
},
198198
},
199-
// {
200-
// files: ['**/*.spec.ts'],
201-
// plugins: {
202-
// vitest
203-
// },
204-
// rules: {
205-
// ...vitest.configs.recommended.rules,
206-
// ...vitest.configs.all.rules,
207-
// '@typescript-eslint/unbound-method': 'off',
208-
// '@typescript-eslint/no-confusing-void-expression': 'off',
209-
// '@typescript-eslint/no-empty-function': "off",
210-
// '@typescript-eslint/no-magic-numbers': 'off',
211-
// '@typescript-eslint/no-non-null-asserted-optional-chain': 'off',
212-
// 'vitest/consistent-test-filename': 'off',
213-
// 'vitest/max-expects': 'off',
214-
// 'vitest/no-hooks': 'off',
215-
// 'vitest/prefer-expect-assertions': 'off',
216-
// 'vitest/prefer-strict-equal': 'error',
217-
// 'vitest/valid-title': 'off',
218-
// },
219-
// },
199+
{
200+
files: ['**/*.spec.ts'],
201+
plugins: {
202+
vitest
203+
},
204+
rules: {
205+
...vitest.configs.recommended.rules,
206+
...vitest.configs.all.rules,
207+
'@typescript-eslint/unbound-method': 'off',
208+
'@typescript-eslint/no-confusing-void-expression': 'off',
209+
'@typescript-eslint/no-empty-function': "off",
210+
'@typescript-eslint/no-magic-numbers': 'off',
211+
'@typescript-eslint/no-non-null-asserted-optional-chain': 'off',
212+
'vitest/consistent-test-filename': 'off',
213+
'vitest/max-expects': 'off',
214+
'vitest/no-hooks': 'off',
215+
'vitest/prefer-expect-assertions': 'off',
216+
'vitest/prefer-strict-equal': 'error',
217+
'vitest/valid-title': 'off',
218+
},
219+
},
220220
);

jest.config.js

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

0 commit comments

Comments
 (0)