I’m using rails in action, but I’m having a problem with this scenario.
Feature: Viewing projects
In order to assign tickets to a project
As a user
I want to be able to see a list of available projects
Scenario: Listing all projects
Given there is a project called "TextMate 2"
And I am on the homepage
When I follow "TextMate 2"
Then I should be on the project page for "TextMate 2"
I’m currently having a problem writing cucumber scenarios. The book is a bit outdated in cucumber. Does anyone know of a blog or site that fixed the revisions of cucumber? I found this one, but it’s only in Chapter 3
If you are using the latest version of cucumber it no longer supports web steps such as “I follow” “I see” as they do not help to describe the behavior of the system. It is better to use the latest version and refactor your cucumber steps.
That allows you to move the web step stuff (
I follow,I should seeetc) into the the scenario steps themselves and makes your scenarios much more expressive without the needless detail.If that doesn’t sound to appealing or you want to follow the book examples I suggest you use an older version of cucumber, 1.0.6 should be low enough, but check what version they use in the book.
That said, I strongly recommend the first option so you learn to use Cucumber well.