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

Avoid accurate assertions on error messages

Since there are disparities between the raised error messages on the
different implementations, let's avoid being too accurate.
This commit is contained in:
Robin Dupret 2015-02-27 14:25:43 +01:00
parent 022c8be2cf
commit 586fe4471d
2 changed files with 3 additions and 3 deletions

View file

@ -305,7 +305,7 @@ class DebugExceptionsTest < ActionDispatch::IntegrationTest
assert_response 500
assert_select '#Application-Trace' do
assert_select 'pre code', /\(eval\):1: syntax error, unexpected/
assert_select 'pre code', /syntax error, unexpected/
end
end
@ -332,7 +332,7 @@ class DebugExceptionsTest < ActionDispatch::IntegrationTest
assert_response 500
assert_select '#Application-Trace' do
assert_select 'pre code', /\(eval\):1: syntax error, unexpected/
assert_select 'pre code', /syntax error, unexpected/
end
end

View file

@ -208,7 +208,7 @@ class PolymorphicRoutesTest < ActionController::TestCase
@series.save
polymorphic_url([nil, @series])
end
assert_match(/undefined method `series_url' for/, exception.message)
assert_match(/undefined method `series_url'/, exception.message)
end
end