diff --git a/lib/configs/recommended.js b/lib/configs/recommended.js index 56b10324..3797544d 100644 --- a/lib/configs/recommended.js +++ b/lib/configs/recommended.js @@ -8,7 +8,7 @@ module.exports = { env: { es6: true }, - plugins: ['github', 'prettier', 'eslint-comments', 'import', 'filenames', 'i18n-text'], + plugins: ['github', 'prettier', 'eslint-comments', 'import', 'filenames', 'i18n-text', 'no-only-tests'], rules: { 'constructor-super': 'error', 'eslint-comments/disable-enable-pair': 'off', @@ -85,6 +85,12 @@ module.exports = { 'no-new-symbol': 'error', 'no-obj-calls': 'error', 'no-octal': 'error', + 'no-only-tests/no-only-tests': [ + 'error', + { + block: ['describe', 'it', 'context', 'test', 'tape', 'fixture', 'serial', 'suite'] + } + ], 'no-redeclare': 'error', 'no-regex-spaces': 'error', 'no-return-assign': 'error', diff --git a/package-lock.json b/package-lock.json index 2f5fb9f6..fd0afca5 100644 --- a/package-lock.json +++ b/package-lock.json @@ -15,6 +15,7 @@ "eslint-plugin-filenames": "^1.3.2", "eslint-plugin-i18n-text": "^1.0.1", "eslint-plugin-import": "^2.22.1", + "eslint-plugin-no-only-tests": "^2.6.0", "eslint-plugin-prettier": "^3.3.1", "eslint-rule-documentation": ">=1.0.0", "prettier": "^2.2.1", @@ -1050,6 +1051,14 @@ "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" }, + "node_modules/eslint-plugin-no-only-tests": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-no-only-tests/-/eslint-plugin-no-only-tests-2.6.0.tgz", + "integrity": "sha512-T9SmE/g6UV1uZo1oHAqOvL86XWl7Pl2EpRpnLI8g/bkJu+h7XBCB+1LnubRZ2CUQXj805vh4/CYZdnqtVaEo2Q==", + "engines": { + "node": ">=4.0.0" + } + }, "node_modules/eslint-plugin-prettier": { "version": "3.3.1", "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-3.3.1.tgz", @@ -3975,6 +3984,11 @@ } } }, + "eslint-plugin-no-only-tests": { + "version": "2.6.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-no-only-tests/-/eslint-plugin-no-only-tests-2.6.0.tgz", + "integrity": "sha512-T9SmE/g6UV1uZo1oHAqOvL86XWl7Pl2EpRpnLI8g/bkJu+h7XBCB+1LnubRZ2CUQXj805vh4/CYZdnqtVaEo2Q==" + }, "eslint-plugin-prettier": { "version": "3.3.1", "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-3.3.1.tgz", diff --git a/package.json b/package.json index 5d22076f..5f8d7985 100644 --- a/package.json +++ b/package.json @@ -32,6 +32,7 @@ "eslint-plugin-filenames": "^1.3.2", "eslint-plugin-i18n-text": "^1.0.1", "eslint-plugin-import": "^2.22.1", + "eslint-plugin-no-only-tests": "^2.6.0", "eslint-plugin-prettier": "^3.3.1", "eslint-rule-documentation": ">=1.0.0", "prettier": "^2.2.1",