From 5543bde08e4e03e8865adcf312352563286fe732 Mon Sep 17 00:00:00 2001 From: "Philip (flip) Kromer" Date: Mon, 8 Aug 2022 18:01:23 -0500 Subject: [PATCH] chore: added mocha linter --- package-lock.json | 39 +++++++++++++++++++++++++++++++++++++++ package.json | 8 +++++++- 2 files changed, 46 insertions(+), 1 deletion(-) diff --git a/package-lock.json b/package-lock.json index 821609e9..c6995a47 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,6 +16,7 @@ "asciitree": "^1.0.2", "damerau-levenshtein": "^1.0.7", "eslint": "^8.2.0", + "eslint-plugin-mocha": "^10.1.0", "leven": "^3.1.0", "lodash": "^4.17.21", "matcha": "^0.7.0", @@ -537,6 +538,22 @@ "url": "https://opencollective.com/eslint" } }, + "node_modules/eslint-plugin-mocha": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-mocha/-/eslint-plugin-mocha-10.1.0.tgz", + "integrity": "sha512-xLqqWUF17llsogVOC+8C6/jvQ+4IoOREbN7ZCHuOHuD6cT5cDD4h7f2LgsZuzMAiwswWE21tO7ExaknHVDrSkw==", + "dev": true, + "dependencies": { + "eslint-utils": "^3.0.0", + "rambda": "^7.1.0" + }, + "engines": { + "node": ">=14.0.0" + }, + "peerDependencies": { + "eslint": ">=7.0.0" + } + }, "node_modules/eslint-scope": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-6.0.0.tgz", @@ -1410,6 +1427,12 @@ "node": ">=6" } }, + "node_modules/rambda": { + "version": "7.2.1", + "resolved": "https://registry.npmjs.org/rambda/-/rambda-7.2.1.tgz", + "integrity": "sha512-Wswj8ZvzdI3VhaGPkZAxaCTwuMmGtgWt7Zxsgyo4P+iTmVnkojvyWaOep5q3ZjMIecW0wtQa66GWxaKkZ24RAA==", + "dev": true + }, "node_modules/randombytes": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", @@ -2238,6 +2261,16 @@ "v8-compile-cache": "^2.0.3" } }, + "eslint-plugin-mocha": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-mocha/-/eslint-plugin-mocha-10.1.0.tgz", + "integrity": "sha512-xLqqWUF17llsogVOC+8C6/jvQ+4IoOREbN7ZCHuOHuD6cT5cDD4h7f2LgsZuzMAiwswWE21tO7ExaknHVDrSkw==", + "dev": true, + "requires": { + "eslint-utils": "^3.0.0", + "rambda": "^7.1.0" + } + }, "eslint-scope": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-6.0.0.tgz", @@ -2894,6 +2927,12 @@ "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true }, + "rambda": { + "version": "7.2.1", + "resolved": "https://registry.npmjs.org/rambda/-/rambda-7.2.1.tgz", + "integrity": "sha512-Wswj8ZvzdI3VhaGPkZAxaCTwuMmGtgWt7Zxsgyo4P+iTmVnkojvyWaOep5q3ZjMIecW0wtQa66GWxaKkZ24RAA==", + "dev": true + }, "randombytes": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", diff --git a/package.json b/package.json index 4efe74d4..1fb3a229 100644 --- a/package.json +++ b/package.json @@ -80,6 +80,7 @@ "asciitree": "^1.0.2", "damerau-levenshtein": "^1.0.7", "eslint": "^8.2.0", + "eslint-plugin-mocha": "^10.1.0", "leven": "^3.1.0", "lodash": "^4.17.21", "matcha": "^0.7.0", @@ -90,7 +91,10 @@ "typescript": "^4.5.2" }, "eslintConfig": { - "extends": "@yomguithereal/eslint-config", + "extends": [ + "plugin:mocha/recommended", + "@yomguithereal/eslint-config" + ], "parserOptions": { "ecmaVersion": 6, "ecmaFeatures": { @@ -98,6 +102,8 @@ } }, "rules": { + "mocha/no-identical-title": 0, + "mocha/no-setup-in-describe": 0, "no-new": 0 } }