From af47ea7c8c3a6de72136ee5158c187802c25d852 Mon Sep 17 00:00:00 2001 From: Guillaume Clochard Date: Thu, 15 Oct 2020 08:07:26 +0200 Subject: [PATCH 1/3] fix(eslint-config-jest): remove old jest/no-test-callback --- packages/eslint-config-jest/CHANGELOG.md | 4 ++++ packages/eslint-config-jest/index.js | 1 - 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/eslint-config-jest/CHANGELOG.md b/packages/eslint-config-jest/CHANGELOG.md index 7723e6f9..0e324d7e 100644 --- a/packages/eslint-config-jest/CHANGELOG.md +++ b/packages/eslint-config-jest/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Fixes + +- Remove old `jest/no-test-callback` rule + ## [1.1.0] ### Changed diff --git a/packages/eslint-config-jest/index.js b/packages/eslint-config-jest/index.js index ee5771d4..28317251 100644 --- a/packages/eslint-config-jest/index.js +++ b/packages/eslint-config-jest/index.js @@ -37,7 +37,6 @@ module.exports = { 'jest/no-truthy-falsy': 'error', 'jest/prefer-to-contain': 'error', 'jest/prefer-called-with': 'error', - 'jest/no-test-callback': 'error', }, }, ], From 46242e95d48049650c0dbb90daa284321cfab9ef Mon Sep 17 00:00:00 2001 From: Guillaume Clochard Date: Thu, 15 Oct 2020 08:17:03 +0200 Subject: [PATCH 2/3] feat(eslint-config-jest): add new rules --- packages/eslint-config-jest/CHANGELOG.md | 4 ++ packages/eslint-config-jest/index.js | 9 ++++ packages/eslint-config-jest/package-lock.json | 48 +++++++++---------- 3 files changed, 37 insertions(+), 24 deletions(-) diff --git a/packages/eslint-config-jest/CHANGELOG.md b/packages/eslint-config-jest/CHANGELOG.md index 0e324d7e..a54926e5 100644 --- a/packages/eslint-config-jest/CHANGELOG.md +++ b/packages/eslint-config-jest/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Changes + +- Add new rules + ### Fixes - Remove old `jest/no-test-callback` rule diff --git a/packages/eslint-config-jest/index.js b/packages/eslint-config-jest/index.js index 28317251..d77457de 100644 --- a/packages/eslint-config-jest/index.js +++ b/packages/eslint-config-jest/index.js @@ -37,6 +37,15 @@ module.exports = { 'jest/no-truthy-falsy': 'error', 'jest/prefer-to-contain': 'error', 'jest/prefer-called-with': 'error', + 'jest/no-deprecated-functions': 'error', + 'jest/no-interpolation-in-snapshots': 'error', + 'jest/valid-title': 'error', + 'jest/no-conditional-expect': 'error', + 'jest/no-duplicate-hooks': 'error', + 'jest/no-export': 'error', + 'jest/no-mocks-import': 'error', + 'jest/no-standalone-expect': 'error', + 'jest/require-top-level-describe': 'error', }, }, ], diff --git a/packages/eslint-config-jest/package-lock.json b/packages/eslint-config-jest/package-lock.json index 0271a368..c4238c26 100644 --- a/packages/eslint-config-jest/package-lock.json +++ b/packages/eslint-config-jest/package-lock.json @@ -1,6 +1,6 @@ { "name": "@iadvize-oss/eslint-config-jest", - "version": "1.0.0", + "version": "1.1.0", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -215,14 +215,14 @@ } }, "@typescript-eslint/experimental-utils": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.4.0.tgz", - "integrity": "sha512-01+OtK/oWeSJTjQcyzDztfLF1YjvKpLFo+JZmurK/qjSRcyObpIecJ4rckDoRCSh5Etw+jKfdSzVEHevh9gJ1w==", + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.4.1.tgz", + "integrity": "sha512-Nt4EVlb1mqExW9cWhpV6pd1a3DkUbX9DeyYsdoeziKOpIJ04S2KMVDO+SEidsXRH/XHDpbzXykKcMTLdTXH6cQ==", "requires": { "@types/json-schema": "^7.0.3", - "@typescript-eslint/scope-manager": "4.4.0", - "@typescript-eslint/types": "4.4.0", - "@typescript-eslint/typescript-estree": "4.4.0", + "@typescript-eslint/scope-manager": "4.4.1", + "@typescript-eslint/types": "4.4.1", + "@typescript-eslint/typescript-estree": "4.4.1", "eslint-scope": "^5.0.0", "eslint-utils": "^2.0.0" }, @@ -238,26 +238,26 @@ } }, "@typescript-eslint/scope-manager": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.4.0.tgz", - "integrity": "sha512-r2FIeeU1lmW4K3CxgOAt8djI5c6Q/5ULAgdVo9AF3hPMpu0B14WznBAtxrmB/qFVbVIB6fSx2a+EVXuhSVMEyA==", + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.4.1.tgz", + "integrity": "sha512-2oD/ZqD4Gj41UdFeWZxegH3cVEEH/Z6Bhr/XvwTtGv66737XkR4C9IqEkebCuqArqBJQSj4AgNHHiN1okzD/wQ==", "requires": { - "@typescript-eslint/types": "4.4.0", - "@typescript-eslint/visitor-keys": "4.4.0" + "@typescript-eslint/types": "4.4.1", + "@typescript-eslint/visitor-keys": "4.4.1" } }, "@typescript-eslint/types": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.4.0.tgz", - "integrity": "sha512-nU0VUpzanFw3jjX+50OTQy6MehVvf8pkqFcURPAE06xFNFenMj1GPEI6IESvp7UOHAnq+n/brMirZdR+7rCrlA==" + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.4.1.tgz", + "integrity": "sha512-KNDfH2bCyax5db+KKIZT4rfA8rEk5N0EJ8P0T5AJjo5xrV26UAzaiqoJCxeaibqc0c/IvZxp7v2g3difn2Pn3w==" }, "@typescript-eslint/typescript-estree": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.4.0.tgz", - "integrity": "sha512-Fh85feshKXwki4nZ1uhCJHmqKJqCMba+8ZicQIhNi5d5jSQFteWiGeF96DTjO8br7fn+prTP+t3Cz/a/3yOKqw==", + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.4.1.tgz", + "integrity": "sha512-wP/V7ScKzgSdtcY1a0pZYBoCxrCstLrgRQ2O9MmCUZDtmgxCO/TCqOTGRVwpP4/2hVfqMz/Vw1ZYrG8cVxvN3g==", "requires": { - "@typescript-eslint/types": "4.4.0", - "@typescript-eslint/visitor-keys": "4.4.0", + "@typescript-eslint/types": "4.4.1", + "@typescript-eslint/visitor-keys": "4.4.1", "debug": "^4.1.1", "globby": "^11.0.1", "is-glob": "^4.0.1", @@ -274,11 +274,11 @@ } }, "@typescript-eslint/visitor-keys": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.4.0.tgz", - "integrity": "sha512-oBWeroUZCVsHLiWRdcTXJB7s1nB3taFY8WGvS23tiAlT6jXVvsdAV4rs581bgdEjOhn43q6ro7NkOiLKu6kFqA==", + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.4.1.tgz", + "integrity": "sha512-H2JMWhLaJNeaylSnMSQFEhT/S/FsJbebQALmoJxMPMxLtlVAMy2uJP/Z543n9IizhjRayLSqoInehCeNW9rWcw==", "requires": { - "@typescript-eslint/types": "4.4.0", + "@typescript-eslint/types": "4.4.1", "eslint-visitor-keys": "^2.0.0" }, "dependencies": { From 36cb9615ccf4ece00b4f67357bdcde24ba49d494 Mon Sep 17 00:00:00 2001 From: Guillaume Clochard Date: Thu, 15 Oct 2020 08:35:23 +0200 Subject: [PATCH 3/3] feat(eslint-config-jest): allow eslint@7 --- packages/eslint-config-jest/CHANGELOG.md | 1 + packages/eslint-config-jest/package.json | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/eslint-config-jest/CHANGELOG.md b/packages/eslint-config-jest/CHANGELOG.md index a54926e5..9962f679 100644 --- a/packages/eslint-config-jest/CHANGELOG.md +++ b/packages/eslint-config-jest/CHANGELOG.md @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Changes - Add new rules +- Allow eslint@7 ### Fixes diff --git a/packages/eslint-config-jest/package.json b/packages/eslint-config-jest/package.json index 4a84d0bf..c61c9994 100644 --- a/packages/eslint-config-jest/package.json +++ b/packages/eslint-config-jest/package.json @@ -19,7 +19,7 @@ "@iadvize-oss/eslint-config": "^1.2.1" }, "peerDependencies": { - "eslint": "^6.8.0" + "eslint": "^6.8.0 || ^7.0.0" }, "dependencies": { "@rushstack/eslint-patch": "^1.0.5",