Comments (10)
We could provide an option that allows for ignoring the check for describe()
.
{
"jest/lowercase-name": ["error", {
"ignore": ["describe"]
}]
}
I'm also wondering if lowercase-name
should check describe()
at all, or if only checking it()
and test()
is more valuable. 🤔
from eslint-plugin-jest.
from eslint-plugin-jest.
I like the idea of a regex (and an ignore
array). PR welcome for both!
from eslint-plugin-jest.
This code introduced in #74 could be a starting point for introducing an ignore
option to the lowercase-name
rule.
eslint-plugin-jest/rules/no-hooks.js
Lines 30 to 35 in 47eb6c2
from eslint-plugin-jest.
I submitted a PR to add the ignore
option for this rule. I started to do some work on regex but it doesn't really feel like the description message regex belongs in the lowercase-name
rule. Thoughts?
from eslint-plugin-jest.
maybe rename the rule to name
, naming-style
or something along those lines?
from eslint-plugin-jest.
Renaming it is a breaking change... We have a few breaking changes lined up anyways, so not a blocker. Worth it, though?
from eslint-plugin-jest.
Unsure! could maybe duplicate it into the new name & deprecate old, if you want a smoother transition (but a bit more annoying to maintain)
from eslint-plugin-jest.
This should be covered by the new option, agreed @nevir?
Might be worth opening up a new issues for renaming the option. My vote is for a new major once node 4 is EOL in April anyways 🙂
from eslint-plugin-jest.
🎉 This issue has been resolved in version 21.15.0 🎉
The release is available on:
Your semantic-release bot 📦🚀
from eslint-plugin-jest.
Related Issues (20)
- Unknown package installing eslint-plugin-jest HOT 2
- [valid-expect] `minmum` is perhaps `maxmum` HOT 4
- [`require-hook`] Add option to allow class calls HOT 2
- [valid-title] static class string name property not allowed HOT 1
- Plugin is preventing upgrades to `@typescript-eslint` packages HOT 5
- Support ESLint "flat" configs HOT 8
- Feature Request: Extend ESLint Plugin Jest for Custom Test and Describe Function Recognition HOT 3
- New rule to prevent to use `expect(query*(...)).toBeDefined();` HOT 2
- New rule to forbid to use `expect(find*(...)).toBeTruthy();` HOT 2
- Feature Request: Make this plugin work with bun HOT 7
- eslint-plugin-node is obsolete HOT 1
- `no-focused-tests` should highlight only `fit` and `fdescribe` instead of the whole thing HOT 4
- Feature: Generate typings for rules etc. HOT 4
- [new-rule] Force to use `jest.mocked(fn)` instead of `fn as jest.Mock` HOT 1
- Results of weekly scheduled smoke test HOT 5
- [expect-expect and no-standalone-expect] `additionalTestBlockFunctions` does not recognize `test.each`-like functions HOT 3
- [no-test-return-statement] does not trigger for arrow functions without a body HOT 3
- Add support for `typescript-eslint` v7 HOT 4
- Is `environments.globals` misconfigured? HOT 15
- [max-expects] does not reset counter with fakeAsync in angular HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eslint-plugin-jest.