The Holy Trinity: Given, When, Then
Philosophy convinces you why Gherkin matters. This module teaches you how to actually write it — the strict grammar that makes a scenario both machine-parseable and human-readable at the same time.
Why This Module Matters
Gherkin looks like plain English, which tricks people into treating it loosely. It isn't loose. Every keyword has an exact job, and mixing them up produces scenarios that are technically valid but practically useless — vague, untestable, or hiding two checks inside one.
What You'll Learn
- The non-negotiable rules of Gherkin syntax and the standard keyword order
Given— establishing preconditions and context, not actionsWhen— the single trigger action that causes something to happenThen— the observable, verifiable outcome — and why "Then" isn't the place for setupAnd/But— extending any step without changing its logical role- The "one scenario, one business check" rule, and why violating it quietly kills your test suite's readability
Your Practice Challenge
After the lessons, you'll take on Number Summation (Gherkin) — an interactive challenge where you assemble six scenarios for a number-addition feature entirely from dropdowns: positive numbers, negative numbers, empty fields, and overflow. No free text to hide behind — every choice has to be the correct Given, When, or Then for that case.