Skip to content

Commit

Permalink
chore(lint): turn the ESLint rule no-useless-call on as an error (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
mrazauskas authored Apr 4, 2022
1 parent 80cf800 commit d873e2c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@ module.exports = {
'no-unused-expressions': 'off',
'no-unused-vars': ['error', {argsIgnorePattern: '^_'}],
'no-use-before-define': 'off',
'no-useless-call': 'warn',
'no-useless-call': 'error',
'no-useless-computed-key': 'error',
'no-useless-concat': 'error',
'no-var': 'error',
Expand Down
4 changes: 2 additions & 2 deletions packages/jest-mock/src/__tests__/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -442,9 +442,9 @@ describe('moduleMocker', () => {
expect(fn.mock.contexts[2]).toBe(ctx2);

// null context
fn.apply(null, []);
fn.apply(null, []); // eslint-disable-line no-useless-call
expect(fn.mock.contexts[3]).toBe(null);
fn.call(null);
fn.call(null); // eslint-disable-line no-useless-call
expect(fn.mock.contexts[4]).toBe(null);
fn.bind(null)();
expect(fn.mock.contexts[5]).toBe(null);
Expand Down

0 comments on commit d873e2c

Please sign in to comment.