Skip to content

Commit

Permalink
Test(form-validations): Use jest-config-spirit common preset
Browse files Browse the repository at this point in the history
  • Loading branch information
literat committed May 15, 2024
1 parent de14db7 commit d81f1ef
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 50 deletions.
49 changes: 0 additions & 49 deletions packages/form-validations/config/jest/config.js

This file was deleted.

13 changes: 13 additions & 0 deletions packages/form-validations/jest.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
const config = {
preset: 'jest-config-spirit',

// The test environment that will be used for testing.
// https://jestjs.io/docs/configuration#testenvironment-string
testEnvironment: 'jsdom',

// A list of paths to modules that run some code to configure or set up the testing framework before each test.
// https://jestjs.io/docs/configuration#setupfilesafterenv-array
setupFilesAfterEnv: ['@testing-library/jest-dom'],
};

export default config;
2 changes: 1 addition & 1 deletion packages/form-validations/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"lint": "eslint ./",
"lint:fix": "yarn lint --fix",
"test": "npm-run-all lint test:unit:coverage types",
"test:unit": "jest --config ./config/jest/config.js",
"test:unit": "jest",
"test:unit:watch": "yarn test:unit --watchAll",
"test:unit:coverage": "yarn test:unit --coverage",
"types": "tsc"
Expand Down

0 comments on commit d81f1ef

Please sign in to comment.