Write and maintain Behavior-Driven Development tests with Gherkin and Cucumber. Use when defining acceptance scenarios, writing feature files, implementing step definitions, running Three Amigos sessions, or diagnosing BDD test quality issues. Keywords: bdd, gherkin, cucumber, given when then, feature files, step definitions, acceptance criteria, three amigos, example mapping.
Does it follow best practices?
Evaluation — 96%
↑ 1.04xAgent success when using this tile
Validation for skill structure
# Install Cucumber.js
bun add -D @cucumber/cucumber
# Install TypeScript support
bun add -D typescript ts-node @types/nodefeatures/
lobby/
create-lobby.feature
join-lobby.feature
game/
player-movement.feature
game-completion.feature
support/
world.ts # Custom World class
steps.ts # Step definitions
hooks.ts # Before/After hooks
cucumber.js # Cucumber configurationcucumber.js
module.exports = {
default: {
require: ["features/support/**/*.ts"],
requireModule: ["ts-node/register"],
format: ["progress-bar", "html:reports/cucumber-report.html"],
formatOptions: { snippetInterface: "async-await" },
},
};# Run all features
npx cucumber-js
# Run specific feature file
npx cucumber-js features/lobby/create-lobby.feature
# Run specific scenario by line number
npx cucumber-js features/lobby/create-lobby.feature:10
# Run with tags
npx cucumber-js --tags "@mvp and not @wip"
# Dry run (validate syntax without running)
npx cucumber-js --dry-run
# Generate step definition snippets for undefined steps
npx cucumber-js --format snippets{
"scripts": {
"test": "cucumber-js",
"test:ci": "cucumber-js --profile ci",
"test:smoke": "cucumber-js --tags @smoke",
"test:wip": "cucumber-js --tags @wip"
}
}