Gherkin

Gherkin image
Gherkin is a domain-specific language (DSL) used primarily in behaviour-driven development (BDD) to define test cases in a human-readable format. It's the language that Cucumber, a popular BDD tool, uses to specify the behaviour of software systems. Gherkin's syntax is designed to be easily understood by both technical and non-technical team members, promoting collaboration and clear communication about requirements.

The Cucumber Book by Matt Wynne and Aslak Hellesøy (2012, p7), says that Gherkin is a list of steps for a Cucumber test to work through, and so are the criteria used to test the work.

Example:
Feature: User Login
Scenario: Successful Login
Given the user is on the login page
When the user enters valid credentials
Then the user should be logged in
Explore MoT
RiskStorming: Artificial Intelligence image
RiskStorming; Artificial Intelligence is a strategy tool that helps your team to not only identify high value risks, but also set up a plan on how to deal
MoT Software Testing Essentials Certificate image
Boost your career in software testing with the MoT Software Testing Essentials Certificate. Learn essential skills, from basic testing techniques to advanced risk analysis, crafted by industry experts.
Into The Motaverse image
Into the MoTaverse is a podcast by Ministry of Testing, hosted by Rosie Sherry, exploring the people, insights, and systems shaping quality in modern software teams.
Subscribe to our newsletter
We'll keep you up to date on all the testing trends.