Skip to content

Commit

Permalink
ci: run staged files' tests only
Browse files Browse the repository at this point in the history
  • Loading branch information
afonsojramos committed Jul 8, 2024
1 parent cd40d10 commit 43cffd3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 8 deletions.
3 changes: 1 addition & 2 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
pnpx lint-staged
pnpm test
pnpx lint-staged
5 changes: 0 additions & 5 deletions jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,6 @@ const config: Config = {
setupFiles: ['<rootDir>/src/__helpers__/setupEnvVars.js'],
testEnvironment: 'jsdom',
collectCoverage: true,
coverageThreshold: {
global: {
lines: 90,
},
},
moduleNameMapper: {
// Force CommonJS build for http adapter to be available.
// via https://github.com/axios/axios/issues/5101#issuecomment-1276572468
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,7 @@
},
"packageManager": "pnpm@9.5.0",
"lint-staged": {
"*.{js,json,ts,tsx}": "biome format --fix"
"*.{js,json,ts,tsx}": "biome format --fix",
"*.{js,ts,tsx}": "pnpm test -- --onlyChanged -u --passWithNoTests"
}
}

0 comments on commit 43cffd3

Please sign in to comment.