Sign in through GitHub

RailsCasts Pro episodes are now free!

Learn more or hide this

antoniojha's Profile

GitHub User: antoniojha

Comments by

Avatar

Not sure if this is still applicable to you, but I ran into a similar problem and was solved by adding the following code in spec_helper.rb:

Rspec.configure do |config|
config.include Rails.application.routes.url_helpers
...
end

This allows named routes to work in rspec.