eslint-plugin-jest: jest/valid-describe false positive for descibe.each variant

The rule jest/valid-describe errors for the describe.each variant:

describe.each([...data])('Something', data => {
  // ...
})

leads to:

  3:15  error  First argument must be name                    jest/valid-describe
  3:15  error  Describe requires name and callback arguments  jest/valid-describe

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 2
  • Comments: 15 (7 by maintainers)

Most upvoted comments

One step ahead of you šŸ˜‰

Iā€™m going to make a quick fix to ignore each, and open a new issue to support each.

The rule readme actually excludes each:

The following describe function aliases are also validated:

describe describe.only describe.skip fdescribe xdescribe