aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobin Dupret <robin.dupret@gmail.com>2015-02-27 14:25:43 +0100
committerRobin Dupret <robin.dupret@gmail.com>2015-03-02 14:05:07 +0100
commit586fe4471d3a71b7500f734d26b28427332b6e43 (patch)
treeb00f3580fee93df4bb720890b42297d8d1aeef00
parent022c8be2cfee97b76c38e5134aa223f62938d6bf (diff)
downloadrails-586fe4471d3a71b7500f734d26b28427332b6e43.tar.gz
rails-586fe4471d3a71b7500f734d26b28427332b6e43.tar.bz2
rails-586fe4471d3a71b7500f734d26b28427332b6e43.zip
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.
-rw-r--r--actionpack/test/dispatch/debug_exceptions_test.rb4
-rw-r--r--actionview/test/activerecord/polymorphic_routes_test.rb2
2 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/test/dispatch/debug_exceptions_test.rb b/actionpack/test/dispatch/debug_exceptions_test.rb
index 7921f05688..a867aee7ec 100644
--- a/actionpack/test/dispatch/debug_exceptions_test.rb
+++ b/actionpack/test/dispatch/debug_exceptions_test.rb
@@ -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
diff --git a/actionview/test/activerecord/polymorphic_routes_test.rb b/actionview/test/activerecord/polymorphic_routes_test.rb
index 6b51775cf3..34b2698c7f 100644
--- a/actionview/test/activerecord/polymorphic_routes_test.rb
+++ b/actionview/test/activerecord/polymorphic_routes_test.rb
@@ -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