[#66563] Use Vitest ESLint rules

Swap the Jasmine ESLint plugin for Vitest rules so migrated specs are
linted against the APIs used by the new runner.

https://community.openproject.org/wp/66563
This commit is contained in:
Alexander Brandon Coles
2026-05-03 00:02:37 +02:00
parent 6e8510ca1d
commit f075050186
3 changed files with 4 additions and 28 deletions
+4 -10
View File
@@ -1,7 +1,7 @@
import eslint from '@eslint/js';
import globals from 'globals';
import tseslint from 'typescript-eslint';
import jasmine from 'eslint-plugin-jasmine';
import vitest from '@vitest/eslint-plugin';
import angular from 'angular-eslint';
import stylistic from '@stylistic/eslint-plugin';
@@ -159,17 +159,11 @@ export default defineConfig([
},
{
files: ['**/*.spec.ts'],
plugins: { jasmine },
extends: [
jasmine.configs.recommended,
],
...vitest.configs.recommended,
rules: {
/**
* Any template/HTML related rules you wish to use/reconfigure over and above the
* recommended set provided by the @angular-eslint project would go here.
*/
...vitest.configs.recommended.rules,
// jasmine is unusable with unsafe member access, as expect(...) is always any
// vitest expect(...) is always any
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/no-unsafe-call': 'off',
-17
View File
@@ -167,7 +167,6 @@
"browserslist": "^4.28.1",
"eslint": "^9.39.2",
"eslint-plugin-import": "^2.32.0",
"eslint-plugin-jasmine": "^4.2.2",
"eslint-plugin-jsx-a11y": "^6.10.2",
"eslint-plugin-react": "^7.37.5",
"eslint-plugin-react-hooks": "^7.0.1",
@@ -15084,16 +15083,6 @@
"strip-bom": "^3.0.0"
}
},
"node_modules/eslint-plugin-jasmine": {
"version": "4.2.2",
"resolved": "https://registry.npmjs.org/eslint-plugin-jasmine/-/eslint-plugin-jasmine-4.2.2.tgz",
"integrity": "sha512-nALbewRk63uz28UGNhUTJyd6GofXxVNFpWFNAwr9ySc6kpSRIoO4suwZqIYz3cfJmCacilmjp7+1Ocjr7zRagA==",
"dev": true,
"engines": {
"node": ">=8",
"npm": ">=6"
}
},
"node_modules/eslint-plugin-jsx-a11y": {
"version": "6.10.2",
"resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.10.2.tgz",
@@ -36849,12 +36838,6 @@
}
}
},
"eslint-plugin-jasmine": {
"version": "4.2.2",
"resolved": "https://registry.npmjs.org/eslint-plugin-jasmine/-/eslint-plugin-jasmine-4.2.2.tgz",
"integrity": "sha512-nALbewRk63uz28UGNhUTJyd6GofXxVNFpWFNAwr9ySc6kpSRIoO4suwZqIYz3cfJmCacilmjp7+1Ocjr7zRagA==",
"dev": true
},
"eslint-plugin-jsx-a11y": {
"version": "6.10.2",
"resolved": "https://registry.npmjs.org/eslint-plugin-jsx-a11y/-/eslint-plugin-jsx-a11y-6.10.2.tgz",
-1
View File
@@ -45,7 +45,6 @@
"browserslist": "^4.28.1",
"eslint": "^9.39.2",
"eslint-plugin-import": "^2.32.0",
"eslint-plugin-jasmine": "^4.2.2",
"eslint-plugin-jsx-a11y": "^6.10.2",
"eslint-plugin-react": "^7.37.5",
"eslint-plugin-react-hooks": "^7.0.1",