Ghost/ghost/core/test/.eslintrc.js
Daniel Lockyer 89493893d1 Removed all unused variables from test files
- this cleans up all imports or variables that aren't currently being used
- this really helps keep the tests clean by only allowing what is needed
- I've left `should` as an exemption for now because we need to clean up
  how it is used
2023-03-10 14:29:55 +01:00

40 lines
1.1 KiB
JavaScript

module.exports = {
env: {
es6: true,
node: true,
mocha: true
},
plugins: [
'ghost'
],
extends: [
'eslint:recommended',
'plugin:ghost/test'
],
rules: {
// TODO: remove this rule once it's turned into "error" in the base plugin
'no-shadow': 'error',
// these rules were were not previously enforced in our custom rules,
// they're turned off here because they _are_ enforced in our plugin.
// TODO: remove these custom rules and fix the problems in test files where appropriate
camelcase: 'off',
'no-prototype-builtins': 'off',
'no-unused-vars': [
'error',
{
varsIgnorePattern: '^should$'
}
],
'no-useless-escape': 'off',
'ghost/mocha/no-skipped-tests': 'error',
// TODO: remove these custom rules and fix problems in test files
'ghost/mocha/max-top-level-suites': 'off',
'ghost/mocha/no-identical-title': 'off',
'ghost/mocha/no-setup-in-describe': 'off',
'ghost/mocha/no-sibling-hooks': 'off'
}
};