Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: reenable lint for test files #17979

Merged
merged 2 commits into from
Jan 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 1 addition & 11 deletions superset-frontend/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ module.exports = {
'*.stories.jsx',
'fixtures.*',
],
excludedFiles: 'cypress-base/cypress/**/*',
plugins: ['jest', 'jest-dom', 'no-only-tests', 'testing-library'],
env: {
'jest/globals': true,
Expand All @@ -180,17 +181,6 @@ module.exports = {
],
'no-only-tests/no-only-tests': 'error',
'max-classes-per-file': 0,
'@typescript-eslint/no-non-null-assertion': 0,
// TODO: disabled temporarily, re-enable after monorepo
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

'jest/consistent-test-it': 'error',
'jest/expect-expect': 0,
'jest/no-test-prefixes': 0,
'jest/valid-expect-in-promise': 0,
'jest/valid-expect': 0,
'jest/valid-title': 0,
'jest-dom/prefer-to-have-attribute': 0,
'jest-dom/prefer-to-have-text-content': 0,
'jest-dom/prefer-to-have-style': 0,
},
},
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
* under the License.
*/

// do not use react-testing-library in plugins
/* eslint-disable jest-dom/prefer-to-have-attribute */
/* eslint-disable jest-dom/prefer-to-have-text-content */
/* eslint-disable jest-dom/prefer-to-have-style */

import updateTextNode from '../../../src/dimension/svg/updateTextNode';
import createTextNode from '../../../src/dimension/svg/createTextNode';

Expand Down Expand Up @@ -91,3 +96,7 @@ describe('updateTextNode(node, options)', () => {
expect(node.textContent).toEqual('');
});
});

/* eslint-enable jest-dom/prefer-to-have-attribute */
/* eslint-enable jest-dom/prefer-to-have-text-content */
/* eslint-enable jest-dom/prefer-to-have-style */