Then /^I should get a response with status (\d+)$/ do |status| response.status.should include(status) end Capybara Then /^I should...

This card describes a Cucumber step that lets you say: When I perform basic authentication as "username/password" and I visit...

Are you adding a "Then show me the page" and re-run Cucumber whenever there is a failing scenario? Don...

Update: This trick probably isn't very useful anymore in Ruby 2.x. The Ruby GC has improved a lot...

If you want to iterate over a Range, but only look at every n-th element, use the step method...

These steps are now part of Spreewald. The step definitions below allow you to test the filename suggested by the...

The step definitions below allow you to write this in both Webrat and Capybara: When I follow "Download as PDF...

Our collection of the most useful Cucumber steps, Spreewald, now supports exact matching of form fields and lets you use...

When you need to see the content of a page (i.e. not all the HTML but the relevant text body...

Using this step definition you can check if any form field (text field, checkbox, etc) or button is disabled:

You can use these step definitions: Then /^I should not see an error$/ do (200 .. 399).should include(page.status_code...

yehudakatz.com

The first thing you need to understand is that the purpose of refinements in Ruby 2.0 is to make monkey...

This card explains how to install RubyMine for the first time. If you want to upgrade an existing RubyMine installation...

Have you guys ever done the math on that? You asked or allowed for 24000 interruptions from literally every human...

apidock.com

E.g. when you're using a tagging gem, you have seen virtual attributes that get and set a string array...

makandra dev

In order to go back one page in your Cucumber tests, you can use the following step definition for Capybara...

robots.thoughtbot.com

Selenium has been the siren song that continually calls out to us. Unfortunately, in practice we’ve been unable to...

web.archive.org

This step tests whether a given select option comes preselected in the HTML. There is another step to test that...

To only run the next two migrations: rake db:migrate STEP=2 To revert the previous two migrations:

As a user of Bundler you have spent significant time looking at this message: Fetching source index for http://rubygems.org...

This note describes a Cucumber step definition that lets you test whether or not a CSS selector is present on...

blog.jcoglan.com

Terminus is a Capybara driver where most of the driver functions are implemented in client-side JavaScript. It lets you...

github.com

Sometimes you inherit a non Rails or non Rack based web app such as PHP, Perl, Java / JEE, etc. I...

If you previously used version 2.x of Thunderbird and upgraded to 3.x (for example through an Ubuntu release...