Skip to content

Commit 8416d33

Browse files
authored
Merge pull request #45 from levibuzolic/support-eslint-v9
Support ESLint v9
2 parents 8fb57fc + 1daa41b commit 8416d33

9 files changed

Lines changed: 856 additions & 904 deletions

File tree

.github/workflows/tests.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88

99
strategy:
1010
matrix:
11-
node-version: [14, 16, 18]
11+
node-version: [18, 20, 22]
1212

1313
steps:
1414
- uses: actions/checkout@v2
@@ -18,6 +18,12 @@ jobs:
1818
node-version: ${{ matrix.node-version }}
1919
- name: Install dependencies
2020
run: yarn install
21+
- name: TypeScript
22+
run: yarn tsc
23+
- name: ESLint
24+
run: yarn eslint .
25+
- name: Biome
26+
run: yarn biome check
2127
- name: Tests
2228
run: yarn run test
2329
env:

biome.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$schema": "https://biomejs.dev/schemas/1.8.3/schema.json",
3+
"organizeImports": { "enabled": true },
4+
"linter": {
5+
"enabled": true,
6+
"rules": { "recommended": true }
7+
},
8+
"formatter": {
9+
"enabled": true
10+
}
11+
}

eslint.config.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
const plugin = require("./index");
2+
const js = require("@eslint/js");
3+
4+
/** @type {import('eslint').Linter.Config} */
5+
module.exports = [
6+
js.configs.recommended,
7+
{
8+
files: ["**/*.js"],
9+
languageOptions: {
10+
sourceType: "commonjs",
11+
ecmaVersion: "latest",
12+
},
13+
plugins: {
14+
"no-only-tests": plugin,
15+
},
16+
rules: {
17+
"no-only-tests/no-only-tests": "error",
18+
},
19+
},
20+
];

index.js

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
1-
'use strict';
2-
31
module.exports = {
4-
rules: {
5-
'no-only-tests': require('./rules/no-only-tests')
6-
}
2+
rules: {
3+
"no-only-tests": require("./rules/no-only-tests"),
4+
},
75
};

package.json

Lines changed: 40 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,42 @@
11
{
2-
"name": "eslint-plugin-no-only-tests",
3-
"version": "3.2.0",
4-
"description": "ESLint rule for .only blocks in mocha tests",
5-
"keywords": [
6-
"eslint",
7-
"eslintplugin",
8-
"eslint-plugin",
9-
"mocha",
10-
"rule",
11-
"only",
12-
"describe",
13-
"it",
14-
"fixture"
15-
],
16-
"author": "Levi Buzolic",
17-
"main": "index.js",
18-
"files": [
19-
"index.js",
20-
"rules/"
21-
],
22-
"scripts": {
23-
"test": "node tests.js"
24-
},
25-
"devDependencies": {
26-
"eslint": ">=3.0.0"
27-
},
28-
"engines": {
29-
"node": ">=5.0.0"
30-
},
31-
"license": "MIT",
32-
"repository": {
33-
"type": "git",
34-
"url": "git@github.com:levibuzolic/eslint-plugin-no-only-tests.git"
35-
},
36-
"bugs": {
37-
"url": "https://github.com/levibuzolic/no-only-tests/issues"
38-
},
39-
"homepage": "https://github.com/levibuzolic/no-only-tests#readme"
2+
"name": "eslint-plugin-no-only-tests",
3+
"version": "4.0.0",
4+
"description": "ESLint rule for .only blocks in mocha tests",
5+
"keywords": [
6+
"eslint",
7+
"eslintplugin",
8+
"eslint-plugin",
9+
"mocha",
10+
"rule",
11+
"only",
12+
"describe",
13+
"it",
14+
"fixture"
15+
],
16+
"author": "Levi Buzolic",
17+
"main": "index.js",
18+
"files": ["index.js", "rules/"],
19+
"scripts": {
20+
"test": "node tests.js"
21+
},
22+
"devDependencies": {
23+
"@biomejs/biome": "^1.8.3",
24+
"@types/eslint": "^9.6.0",
25+
"@types/eslint__js": "^8.42.3",
26+
"@types/node": "^22.3.0",
27+
"eslint": ">=9.0.0",
28+
"typescript": "^5.5.4"
29+
},
30+
"engines": {
31+
"node": ">=5.0.0"
32+
},
33+
"license": "MIT",
34+
"repository": {
35+
"type": "git",
36+
"url": "git@github.com:levibuzolic/eslint-plugin-no-only-tests.git"
37+
},
38+
"bugs": {
39+
"url": "https://github.com/levibuzolic/no-only-tests/issues"
40+
},
41+
"homepage": "https://github.com/levibuzolic/no-only-tests#readme"
4042
}

0 commit comments

Comments
 (0)