Skip to content

Commit

Permalink
test(api): Setup eslint-plugin-vite (#3587)
Browse files Browse the repository at this point in the history
  • Loading branch information
DafyddLlyr authored Aug 29, 2024
1 parent 8699984 commit f484485
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 2 deletions.
17 changes: 15 additions & 2 deletions api.planx.uk/.eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"prettier"
"prettier",
"plugin:@vitest/legacy-recommended"
],
"rules": {
"@typescript-eslint/no-explicit-any": "warn",
Expand All @@ -17,7 +18,19 @@
}
],
"@typescript-eslint/no-non-null-assertion": "off",
"no-nested-ternary": "error"
"no-nested-ternary": "error",
"@vitest/expect-expect": [
"error",
{
"assertFunctionNames": [
"expect",
// Allow Supertest expect() calls
"get.expect",
"post.expect",
"supertest.**.expect"
]
}
]
},
"globals": {
"require": "readonly",
Expand Down
1 change: 1 addition & 0 deletions api.planx.uk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@
"@typescript-eslint/eslint-plugin": "^5.62.0",
"@typescript-eslint/parser": "^5.62.0",
"@vitest/coverage-istanbul": "^2.0.5",
"@vitest/eslint-plugin": "^1.1.0",
"@vitest/ui": "^2.0.5",
"dotenv": "^16.4.5",
"eslint": "^8.57.0",
Expand Down
23 changes: 23 additions & 0 deletions api.planx.uk/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f484485

Please sign in to comment.