Skip to content

Commit

Permalink
new suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
prayanshchh committed Nov 26, 2024
1 parent 55ec1cc commit 99d8566
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,12 @@ jobs:
run: |
npm run test:vitest:coverage
- name: Merge Coverage Reports
if: steps.changed-files.outputs.only_changed != 'true'
run: |
npx nyc merge ./coverage ./coverage-vitest ./merged-coverage
mv ./merged-coverage/coverage-final.json ./coverage/coverage-final.json
- name: TypeScript compilation for changed files
run: |
for file in ${{ steps.changed-files.outputs.all_files }}; do
Expand Down
14 changes: 12 additions & 2 deletions vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,21 @@ export default defineConfig({
include: ['src/**/*.spec.{js,jsx,ts,tsx}'],
globals: true,
environment: 'jsdom',
setupFiles: ['src/test/setup.ts'],
coverage: {
enabled: true,
provider: 'istanbul',
reportsDirectory: './coverage',
exclude: ['node_modules', 'dist', '**/*.spec.{js,jsx,ts,tsx}'],
reportsDirectory: './coverage-vitest',
exclude: [
'node_modules',
'dist',
'**/*.{spec,test}.{js,jsx,ts,tsx}',
'coverage/**',
'**/index.{js,ts}',
'**/*.d.ts',
'src/test/**',
'vitest.config.ts',
],
reporter: ['text', 'html', 'text-summary', 'lcov'],
},
},
Expand Down

0 comments on commit 99d8566

Please sign in to comment.