This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
Feature-Coupled Steps (Antipattern)
Feature-coupled steps are steps that can’t be used across features or scenarios. This is evil because it leads to an explosion of step definitions, code duplication and high maintenance costs.
Example
An imaginary resume application could have the following features and step files:
features/ +--edit_work_experience.feature +--edit_languages.feature +--edit_education.feature +--steps/ +--edit_work_experience_steps.rb +--edit_languages_steps.rb +--edit_education_steps.rb
The edit_work_experience.feature could have the following scenario:
Scenario: add description Given I have a CV and I'm on the edit description page And I fill in "Description" with "Cucumber BDD tool" When I press "Save" Then I should see "Cucumber BDD tool" under "Descriptions"
The edit_work_experience_steps.rb could be implemented like this:
Given /I have a CV and I'm on the edit description page/ do
@employee = Employee.create!(:name => 'Sally')
@employee.create_cv
visits("/employees/#{@employee.id}/descriptions/new")
end
How to fix
- Break up Conjunction Steps steps into individual steps.
- Organise steps by domain concept. See Step Organisation.
- Rename step.rb files to a domain-related name (rather than feature/scenario-related name).






