Skip to content

Commit

Permalink
chore(test): add lint + test config
Browse files Browse the repository at this point in the history
  • Loading branch information
jfactory-es committed Nov 1, 2024
1 parent d9e0a5a commit 354dd64
Show file tree
Hide file tree
Showing 2 changed files with 58 additions and 0 deletions.
50 changes: 50 additions & 0 deletions test/promises-aplus-fork/eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
export default [
{
languageOptions: {
ecmaVersion: 2021
},
rules: {
// "camelcase": ["error", { "properties": "always" }],
// "curly": ["error", "all"],
// "eqeqeq": ["error", "always"],
// "strict": ["error", "global"],
// "no-extra-bind": "error", // Correspond à JSLint `immed`
// "indent": ["error", 2],
// "max-len": ["error", { "code": 120 }],
// "new-cap": ["error"],
// "no-caller": "error", // remplace noarg de JSLint
// "no-new": "error",
// "no-underscore-dangle": ["error", { "allowAfterThis": false }],
// "quotes": ["error", "double"],
// "no-trailing-spaces": "error",
// "no-undef": "error",
// "no-unused-vars": ["error", { "vars": "all", "args": "after-used", "ignoreRestSiblings": false }],
// "space-before-blocks": ["error", "always"],
// "space-before-function-paren": ["error", "never"],
// "keyword-spacing": ["error", { "before": true, "after": true }],
// "space-infix-ops": "error"
}
},
{
files: ["**/lib/*.*js"],
rules: {
"indent": ["error", 4]
}
},
{
files: ["**/*.test.*js"],
languageOptions: {
sourceType: "module",
globals: {
afterEach: "readonly",
beforeEach: "readonly",
describe: "readonly",
it: "readonly",
specify: "readonly"
}
},
rules: {
"indent": ["error", 4]
}
}
]
8 changes: 8 additions & 0 deletions test/promises-aplus-fork/vitest.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { defineConfig } from "vitest/config";

export default defineConfig({
test: {
name: "Promise",
threads: true
}
})

0 comments on commit 354dd64

Please sign in to comment.