Created
January 21, 2014 14:41
-
-
Save firedev/8541276 to your computer and use it in GitHub Desktop.
Fix for Rails locales when testing with Rspec, Capybara etc...
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# spec/support/routing_helper.rb | |
class ActionDispatch::Routing::RouteSet::NamedRouteCollection::UrlHelper | |
def call(t, args) | |
t.url_for(handle_positional_args(t, args, { locale: nil }.merge( @options ), @segment_keys)) | |
end | |
end |
Failure/Error:
def call(t, args)
t.url_for(handle_positional_args(t, args, { locale: nil }.merge( @options ), @segment_keys))
ArgumentError:
wrong number of arguments (3 for 2)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Its not working with rails-4.2.1.