@mscharley/eslint-config 3.0.9 → 3.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Change Log - @mscharley/eslint-config
2
2
 
3
+ ## 3.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 004f0af: Add support the Jest plugin in eslint
8
+
3
9
  ## 3.0.9
4
10
 
5
11
  ### Patch Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mscharley/eslint-config",
3
- "version": "3.0.9",
3
+ "version": "3.1.0",
4
4
  "publishConfig": {
5
5
  "provenance": true
6
6
  },
@@ -26,22 +26,21 @@
26
26
  "url": "https://github.com/mscharley/node-presets/issues"
27
27
  },
28
28
  "homepage": "https://github.com/mscharley/node-presets#readme",
29
- "dependencies": {},
30
29
  "peerDependencies": {
31
30
  "@mscharley/prettier-config": "3.0.4",
32
- "@typescript-eslint/parser": "^7.0.2",
33
31
  "@typescript-eslint/eslint-plugin": "^7.0.2",
32
+ "@typescript-eslint/parser": "^7.0.2",
34
33
  "eslint": "^8.57.0",
35
34
  "eslint-config-prettier": "^9.1.0",
36
35
  "eslint-import-resolver-typescript": "^3.6.1",
37
36
  "eslint-plugin-deprecation": "^2.0.0",
38
37
  "eslint-plugin-import": "^2.29.1",
38
+ "eslint-plugin-jest": "^27.9.0",
39
39
  "eslint-plugin-node": "^11.1.0",
40
40
  "eslint-plugin-prettier": "^5.1.3",
41
41
  "eslint-plugin-react": "^7.33.2",
42
42
  "eslint-plugin-react-hooks": "^4.6.0",
43
43
  "prettier": "^3.2.5",
44
44
  "typescript": "^5.3.3"
45
- },
46
- "devDependencies": {}
45
+ }
47
46
  }
package/testing.json CHANGED
@@ -1,19 +1,36 @@
1
1
  {
2
- "overrides": [
3
- {
4
- // Viteshot support.
5
- "files": ["**/*.screenshot.{jsx,tsx}"],
6
- "rules": {
7
- "@typescript-eslint/explicit-function-return-type": "off",
8
- "@typescript-eslint/explicit-module-boundary-types": "off"
9
- }
10
- },
11
- {
12
- // Jest support.
13
- "files": ["**/__tests__/**/*.{ts,js,tsx,jsx}"],
14
- "rules": {
15
- "@typescript-eslint/consistent-type-assertions": "off"
16
- }
17
- }
18
- ]
2
+ "overrides": [
3
+ {
4
+ // Viteshot support.
5
+ "files": ["**/*.screenshot.{jsx,tsx}"],
6
+ "rules": {
7
+ "@typescript-eslint/explicit-function-return-type": "off",
8
+ "@typescript-eslint/explicit-module-boundary-types": "off"
9
+ }
10
+ },
11
+ {
12
+ // Jest support.
13
+ "files": [
14
+ "**/__tests__/**/*.{ts,js,tsx,jsx}",
15
+ "**/__mocks__/**/*.{ts,js,tsx,jsx}",
16
+ "**/__utils__/**/*.{ts,js,tsx,jsx}"
17
+ ],
18
+ "plugins": ["jest"],
19
+ "extends": ["plugin:jest/style", "plugin:jest/recommended"],
20
+ "rules": {
21
+ "@typescript-eslint/consistent-type-assertions": "off",
22
+ "jest/prefer-todo": "error",
23
+ "jest/no-conditional-in-test": "warn",
24
+ "jest/no-untyped-mock-factory": "error",
25
+ "jest/prefer-called-with": "error",
26
+ "jest/prefer-comparison-matcher": "warn",
27
+ "jest/prefer-equality-matcher": "warn",
28
+ "jest/prefer-lowercase-title": "error",
29
+ "jest/prefer-expect-assertions": [
30
+ "error",
31
+ { "onlyFunctionsWithExpectInLoop": true, "onlyFunctionsWithExpectInCallback": true }
32
+ ]
33
+ }
34
+ }
35
+ ]
19
36
  }