1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Remove 'warning: ambiguous first argument' when running ActionPack tests

Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
This commit is contained in:
Sebastian Martinez 2011-03-29 09:40:42 -03:00 committed by Santiago Pastorino
parent b155fdadf3
commit 52351bcfeb
2 changed files with 4 additions and 4 deletions

View file

@ -56,7 +56,7 @@ module ActionDispatch
mapper = Mapper.new fakeset mapper = Mapper.new fakeset
mapper.match '/*path', :to => 'pages#show' mapper.match '/*path', :to => 'pages#show'
assert_equal '/*path(.:format)', fakeset.conditions.first[:path_info] assert_equal '/*path(.:format)', fakeset.conditions.first[:path_info]
assert_equal /.+?/, fakeset.requirements.first[:path] assert_equal(/.+?/, fakeset.requirements.first[:path])
end end
def test_map_wildcard_with_other_element def test_map_wildcard_with_other_element
@ -73,7 +73,7 @@ module ActionDispatch
mapper.match '/*foo/*bar', :to => 'pages#show' mapper.match '/*foo/*bar', :to => 'pages#show'
assert_equal '/*foo/*bar(.:format)', fakeset.conditions.first[:path_info] assert_equal '/*foo/*bar(.:format)', fakeset.conditions.first[:path_info]
assert_nil fakeset.requirements.first[:foo] assert_nil fakeset.requirements.first[:foo]
assert_equal /.+?/, fakeset.requirements.first[:bar] assert_equal(/.+?/, fakeset.requirements.first[:bar])
end end
def test_map_wildcard_with_format_false def test_map_wildcard_with_format_false

View file

@ -2720,11 +2720,11 @@ class DateHelperTest < ActionView::TestCase
end end
def test_time_tag_pubdate_option def test_time_tag_pubdate_option
assert_match /<time.*pubdate="pubdate">.*<\/time>/, time_tag(Time.now, :pubdate => true) assert_match(/<time.*pubdate="pubdate">.*<\/time>/, time_tag(Time.now, :pubdate => true))
end end
def test_time_tag_with_given_text def test_time_tag_with_given_text
assert_match /<time.*>Right now<\/time>/, time_tag(Time.now, 'Right now') assert_match(/<time.*>Right now<\/time>/, time_tag(Time.now, 'Right now'))
end end
def test_time_tag_with_different_format def test_time_tag_with_different_format