So, I recently started using Rails 3, and I am running my test with the awesome Cucumber framework, and Webrat. To set it up in Rails 3, however, I had to apply a little fix, because my
task kept giving me this lovely error

undefined method `fill_in' for # (NoMethodError)

Now, the fix for this is very easy – you go to your “env.rb” file under features/support, and change :rails to :rack, like this:

Webrat.configure do |config|
  config.mode = :rack
  config.open_error_files = false # Set to true if you want error pages to pop up in the browser
end

And presto! It works!