Skip to content

Commit

Permalink
Merge pull request #47457 from zzak/ruby-3.3/feature/18285
Browse files Browse the repository at this point in the history
Fix ruby:master re: ruby/feature/18285
  • Loading branch information
byroot committed Feb 22, 2023
2 parents 2c97993 + 67748d0 commit 5594c6c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion actionview/test/template/render_test.rb
Expand Up @@ -340,7 +340,7 @@ def test_render_sub_template_with_errors

def test_undefined_method_error_references_named_class
e = assert_raises(ActionView::Template::Error) { @view.render(inline: "<%= undefined %>") }
assert_match(/`undefined' for #<ActionView::Base:0x[0-9a-f]+>/, e.message)
assert_match(/undefined local variable or method `undefined'/, e.message)
end

def test_render_renderable_object
Expand Down
2 changes: 1 addition & 1 deletion activesupport/test/core_ext/time_with_zone_test.rb
Expand Up @@ -1095,7 +1095,7 @@ def test_no_method_error_has_proper_context
e = assert_raises(NoMethodError) {
@twz.this_method_does_not_exist
}
assert_match "undefined method `this_method_does_not_exist' for Fri, 31 Dec 1999 19:00:00.000000000 EST -05:00:ActiveSupport::TimeWithZone", e.message
assert_match(/undefined method `this_method_does_not_exist' for.*ActiveSupport::TimeWithZone/, e.message)
assert_no_match "rescue", e.backtrace.first
end
end
Expand Down
2 changes: 1 addition & 1 deletion railties/test/railties/railtie_test.rb
Expand Up @@ -243,7 +243,7 @@ class Foo < Rails::Railtie
Foo.instance.abc
end

assert_equal("undefined method `abc' for #<RailtiesTest::RailtieTest::Foo>", error.original_message)
assert_match(/undefined method `abc' for.*RailtiesTest::RailtieTest::Foo/, error.original_message)
end
end
end

0 comments on commit 5594c6c

Please sign in to comment.