JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1527
  • Score
    100M100P100Q114803F
  • License ISC

A Gherkin linter/validator written in Javascript.

Package Exports

    Readme

    GPLint (Gherkin/Pickle Linter)

    Test codecov npm

    Uses Gherkin to parse feature files and runs linting against the default rules, and the optional rules you specified in your .gplintrc file.

    Forked from gherkin-lint

    Documentation

    Access to the documentation site to know how to use GPLint: https://gplint.github.io/

    Quickstart

    We encourage to check the site for complete documentation, but as quick start you can follow this:

    Installation

    Install as development dependency:

    npm install --save-dev gplint

    Create basic configuration

    Set some basic rules to validate your gherkin files, to do that, create a file called .gplintrc with the following content:

    .gplintrc

    {
      "allow-all-caps": [
        "error",
        {
          "Global": false,
          "Description": false,
          "ExampleHeader": true,
          "ExampleBody": true
        }
      ],
      "allow-all-lowercase": [
        "error",
        {
          "Global": false,
          "Description": false,
          "Step": true,
          "ExampleHeader": true,
          "ExampleBody": true
        }
      ],
      "file-name": [
        "warn",
        {
          "style": "camelCase",
          "allowAcronyms": true
        }
      ],
      "keywords-in-logical-order": [
        "error",
        {
          "detectMissingKeywords": true
        }
      ],
      "no-superfluous-tags": "warn",
      "no-unnamed-features": "error",
      "no-unnamed-scenarios": "error",
      "no-unused-variables": "warn"
    }

    Run it!

    Run it, checking the Gherkin files you have on test/features folder.

    gplint tests/features