Skip to content

Commit e940cab

Browse files
authored
Merge pull request rails#50638 from dwightwatson/route_defined_bug
Fix undefined method issue in test
2 parents ee169e3 + e358953 commit e940cab

File tree

1 file changed

+1
-1
lines changed
  • actionpack/lib/action_dispatch/testing/assertions

1 file changed

+1
-1
lines changed

actionpack/lib/action_dispatch/testing/assertions/routing.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ def assert_routing(path, options, defaults = {}, extras = {}, message = nil)
248248

249249
# ROUTES TODO: These assertions should really work in an integration context
250250
def method_missing(selector, ...)
251-
if @controller && @routes&.named_routes.route_defined?(selector)
251+
if @controller && @routes&.named_routes&.route_defined?(selector)
252252
@controller.public_send(selector, ...)
253253
else
254254
super

0 commit comments

Comments
 (0)