diff --git a/.eslintrc.js b/.eslintrc.js index 71210e8668413f7878a5ffe629c111bf5d1bb195..47d116601c82b759b1b842bf7f26af56dc8e07c0 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -113,6 +113,9 @@ module.exports = { 'jest/no-test-callback': 0, 'jest/expect-expect': 0, + 'jest/no-done-callback': 0, + 'jest/valid-title': 0, + 'jest/no-conditional-expect': 0, 'unicorn/better-regex': 2, 'unicorn/prefer-trim-start-end': 2, diff --git a/components/affix/__tests__/Affix.test.tsx b/components/affix/__tests__/Affix.test.tsx index b215a9e7b24e71778714c595bb5f1db221580ccd..9281f2a9c7cad19cf84aaf745fa9eac769074f7f 100644 --- a/components/affix/__tests__/Affix.test.tsx +++ b/components/affix/__tests__/Affix.test.tsx @@ -186,7 +186,7 @@ describe('Affix Render', () => { it.each([ { name: 'inner', index: 0 }, { name: 'outer', index: 1 }, - ])(name, async ({ index }) => { + ])('inner or outer', async ({ index }) => { document.body.innerHTML = '
'; const updateCalled = jest.fn(); diff --git a/components/calendar/__tests__/index.test.js b/components/calendar/__tests__/index.test.js index ad603131f36a6602a5116511d96c5c0c85426ce8..c4204c3130d412b33aee174ff52da52eaa37a5b0 100644 --- a/components/calendar/__tests__/index.test.js +++ b/components/calendar/__tests__/index.test.js @@ -214,7 +214,7 @@ describe('Calendar', () => { expect(onValueChange).toHaveBeenCalledWith(value.year('2019').month('3')); }); - it('if start.month > value.month, set value.month to start.month ', () => { + it('if start.month > value.month, set value.month to start.month', () => { const value = new Moment('1990-01-03'); const start = new Moment('2019-11-01'); const end = new Moment('2019-03-01'); @@ -223,7 +223,7 @@ describe('Calendar', () => { expect(onValueChange).toHaveBeenCalledWith(value.year('2019').month('10')); }); - it('if change year and new month > end month, set value.month to end.month ', () => { + it('if change year and new month > end month, set value.month to end.month', () => { const value = new Moment('2018-11-03'); const start = new Moment('2000-01-01'); const end = new Moment('2019-03-01'); diff --git a/components/carousel/__tests__/index.test.js b/components/carousel/__tests__/index.test.js index 8927384cc374a821a1e5473c0a0539a42f43a557..88d91f21bed8bbb129ce87cd3c698aee71574b5f 100644 --- a/components/carousel/__tests__/index.test.js +++ b/components/carousel/__tests__/index.test.js @@ -86,6 +86,7 @@ describe('Carousel', () => { describe('should works for dotPosition', () => { ['left', 'right', 'top', 'bottom'].forEach(dotPosition => { + // eslint-disable-next-line jest/valid-title it(dotPosition, () => { const wrapper = mount(