Learn what defines effective BDD scenarios

Learn what defines effective BDD scenarios is a skill for Claude Code from Intai/story-flow. It costs 22 tokens per session (2,113 once invoked), scanned A, original, MIT.

An interactive lesson on writing BDD scenarios. BDD, or Behavior-Driven Development, describes software behavior in readable scenarios that can also guide automated tests.

In plain words
What is it for?
It is for learning scenario structure, including shared setup and step-by-step behavior, and for understanding how story-flow can turn scenarios into Playwright browser tests.
Why use it?
It explains how to make scenarios precise and complete enough for browser execution and regression testing, reducing ambiguity in automated checks.

Skill for Claude Code

Written for Claude Code: user-invocable in frontmatter. Also seen: names the AskUserQuestion tool.

Part of the junior-flow plugin — 4 skills, 2 commands shipped together

Good fit It is for learning scenario structure, including shared setup and step-by-step behavior, and for understanding how story-flow can turn scenarios into Playwright browser tests.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/intai/story-flow/learn-bdd-scenarios
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Intai/story-flow --skill learn-bdd-scenarios
Clone the repo
git clone --depth 1 https://github.com/Intai/story-flow

Made for: Claude Code.

Or install junior-flow, the plugin that ships this one along with the rest of its 4 skills, 2 commands.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for Learn what defines effective BDD scenarios

README.md
[![agentmods](https://agentmods.dev/badge/skills/intai/story-flow/learn-bdd-scenarios/github.svg)](https://agentmods.dev/skills/intai/story-flow/learn-bdd-scenarios)
Your own site
<a href="https://agentmods.dev/skills/intai/story-flow/learn-bdd-scenarios"><img src="https://agentmods.dev/badge/skills/intai/story-flow/learn-bdd-scenarios/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for Learn what defines effective BDD scenarios

Your own site · 80×15
<a href="https://agentmods.dev/skills/intai/story-flow/learn-bdd-scenarios"><img src="https://agentmods.dev/badge/skills/intai/story-flow/learn-bdd-scenarios.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 22 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,113 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00022 $0.02113
Opus 5 $0.00011 $0.01056
Sonnet 5 $0.00004 $0.00423
Haiku 4.5 $0.00002 $0.00211

Measured 11d ago against content hash 398da2361727, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

Learn what defines effective BDD scenarios scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/junior-flow/skills/learn-bdd-scenarios/SKILL.md · 287 lines

How it starts

The opening of the file, as written. The whole thing — 287 lines — stays where its author put it; the contents beside it link to each section on GitHub.

What Defines Effective, Complete BDD Scenarios

Overview

This learning module helps junior developers understand how to write BDD (Behavior-Driven Development) scenarios that are effective for story-flow's automated testing workflow.

Instructions

Present the following content interactively. After each section, use AskUserQuestion to offer 3 options:

  • "Continue to next section"
  • "Show more examples"
  • "I have a question"

Section 1: The Purpose of BDD Scenarios

Explain that in story-flow, BDD scenarios serve two purposes:

  1. Executable specifications - Claude uses Playwright MCP to execute these scenarios directly in a browser
  2. Regression test generation - With --record flag, scenarios become Playwright .spec.js files

This means scenarios must be:

  • Precise enough for automated execution
  • Complete enough to verify the feature works correctly
  • Structured correctly so Claude can follow them step-by-step

Section 2: Anatomy of an Effective BDD Scenario

Present this structure with explanations:

Feature: [Feature name matching the story]

Background:
  # Shared setup steps that run before EVERY scenario
  Given I am logged in as "[email protected]"
  And I am on the settings page

@purge-data
Scenario: FEAT-01: [Clear, descriptive title]
  # Given - Initial state/context
  Given there are 3 images in the gallery

  # When - The action being tested
  When I click the "Delete" button on the first image
  And I confirm the deletion in the dialog

  # Then - Expected outcome (assertions)
  Then I should see 2 images in the gallery
  And the deleted image should not be visible
  And the image should be removed from S3 bucket

Key elements:

Element Purpose Example
Feature: Groups related scenarios Feature: Image Gallery Management
Background: Shared setup (runs before each scenario) Login, navigation, seed data
@tags Control execution behavior, or label tests for filtering @purge-data, @screenshots, @staging
Scenario: ID: Unique identifier + descriptive title FEAT-01: Delete single image
Given Preconditions/initial state Given there are 3 images
When User actions When I click "Delete"
Then Expected outcomes Then I should see 2 images

Read the full file on GitHub · 287 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 287 lines · 22 tokens per session scan A 398da2361727

Subscribe to this mod's changes

Learn what defines effective BDD scenarios is a skill published in the GitHub repository Intai/story-flow (12 stars, last pushed today), licensed MIT. It adds 22 tokens to every session and 2,113 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories