aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/lib/action_controller/test_case.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/test_case.rb b/actionpack/lib/action_controller/test_case.rb
index 98f70f2336..028a8d3fba 100644
--- a/actionpack/lib/action_controller/test_case.rb
+++ b/actionpack/lib/action_controller/test_case.rb
@@ -93,13 +93,13 @@ module ActionController
rendered = @templates
msg = message || sprintf("expecting <%s> but rendering with <%s>",
options.inspect, rendered.keys)
- assert(msg) do
+ matches_template =
if options
rendered.any? { |t,num| t.match(options) }
else
@templates.blank?
end
- end
+ assert matches_template, msg
when Hash
if options.key?(:layout)
expected_layout = options[:layout]