@ohlori/gherkin-lint
v4.3.2
Published
A Gherkin linter/validator written in javascript
Readme
Gherkin lint
An unofficial fork of gherkin-lint, published as @ohlori/gherkin-lint. Based on upstream 4.2.4.
Current fork version: 4.3.2. It is not affiliated with or endorsed by the original authors.
Changes
- Supports modern Gherkin
Ruleblocks, including Rule-scopedBackgrounds. - Scopes
no-dupe-scenario-namesbyRule: the same scenario name under different Rules is allowed; duplicates under the same Rule (or both at Feature level) are still flagged. - Allows indentation-only blank lines inside DocStrings (
no-trailing-spaces). - Runs the stylish formatter from source and refreshes production dependencies.
no-dupe-scenario-names + Rules example
Rule: Users Tab
Scenario: [Pagination] Next page
Then users on the next page are shown
Rule: Companies Tab
Scenario: [Pagination] Next page
Then companies on the next page are shownThose two scenarios share a name but live under different Rules, so the rule does not report a duplicate.
Configure per-feature duplicate checks like this:
{
"no-dupe-scenario-names": ["on", "in-feature"]
}Install
npm install @ohlori/gherkin-lintSee the original README for CLI usage and the full rule set.
License: ISC
