Skip to content

Commit ea36362

Browse files
committed
feat(jest): source formatting rules from eslint-plugin-jest
1 parent 1826911 commit ea36362

4 files changed

Lines changed: 12 additions & 33 deletions

File tree

README.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ Below is a complete list of the configs provided, and their dependencies:
7676
- `eslint-plugin-prettier`
7777
- `ackama/jest`
7878
- `eslint-plugin-jest`
79-
- `eslint-plugin-jest-formatting`
8079
- `ackama/react`
8180
- `eslint-plugin-prettier`
8281
- `eslint-plugin-react`

jest.js

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,8 @@ const banMatchers = matchers => {
2020

2121
/** @type {import('eslint').Linter.Config} */
2222
const config = {
23-
plugins: ['jest', 'jest-formatting'],
24-
extends: [
25-
'plugin:jest/recommended',
26-
'plugin:jest/style',
27-
'plugin:jest-formatting/recommended'
28-
],
23+
plugins: ['jest'],
24+
extends: ['plugin:jest/recommended', 'plugin:jest/style'],
2925
rules: {
3026
'@typescript-eslint/unbound-method': 'off',
3127
'jest/consistent-test-it': 'error',
@@ -62,7 +58,14 @@ const config = {
6258
'jest/require-to-throw-message': 'error',
6359
'jest/require-top-level-describe': 'error',
6460
'jest/unbound-method': 'error',
65-
'jest/valid-title': 'error'
61+
'jest/valid-title': 'error',
62+
63+
'jest/padding-around-after-all-blocks': 'error',
64+
'jest/padding-around-after-each-blocks': 'error',
65+
'jest/padding-around-before-all-blocks': 'error',
66+
'jest/padding-around-before-each-blocks': 'error',
67+
'jest/padding-around-describe-blocks': 'error',
68+
'jest/padding-around-test-blocks': 'error'
6669
}
6770
};
6871

package-lock.json

Lines changed: 1 addition & 19 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,6 @@
9191
"eslint": "^8.0.1",
9292
"eslint-plugin-import": "^2.22.1",
9393
"eslint-plugin-jest": "^28.0.0",
94-
"eslint-plugin-jest-formatting": "^3.0.0",
9594
"eslint-plugin-jsx-a11y": "^6.3.1",
9695
"eslint-plugin-n": "^17.0.0",
9796
"eslint-plugin-prettier": "^5.0.0",
@@ -117,8 +116,7 @@
117116
"@typescript-eslint/parser": "^7.0.0",
118117
"eslint": ">= 8.0",
119118
"eslint-plugin-import": ">= 2.21",
120-
"eslint-plugin-jest": "^28.0.0",
121-
"eslint-plugin-jest-formatting": "^3.0.0",
119+
"eslint-plugin-jest": "^28.8.0",
122120
"eslint-plugin-jsx-a11y": "^6.0.0",
123121
"eslint-plugin-n": ">= 14.0.0",
124122
"eslint-plugin-prettier": ">= 3.1",
@@ -139,9 +137,6 @@
139137
"eslint-plugin-jest": {
140138
"optional": true
141139
},
142-
"eslint-plugin-jest-formatting": {
143-
"optional": true
144-
},
145140
"eslint-plugin-jsx-a11y": {
146141
"optional": true
147142
},

0 commit comments

Comments
 (0)