npm

Need private packages and team management tools?Check out npm Orgs. »

gherkin-ast

2.0.1 • Public • Published

gherkin-ast

Build Status dependency Status devDependency Status

Models for Gherkin feature files

AST

The API provides types to be able to handle different parts of Gherkin feature files.

In TypeScript:

import {Feature, Scenario /*, Background, ... */} from "gherkin-ast";

OR in JavaScript:

const {Feature, Scenario /*, Background, ... */} = require("gherkin-ast");
const feature = new Feature("Feature", "Displaying documents");
feature.elements.push(new Scenario("Scenario", "Opening a document"));
// ...

For detailed documentation see the TypeDocs documentation.

NOTE parse functions only support AST provided by the parser of gherkin@6.

install

npm i gherkin-ast

Downloadsweekly downloads

4,482

version

2.0.1

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
  • avatar
  • avatar
Report a vulnerability