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

Fix incorrect assert_block -> assert conversion. Assumed too much from the MiniTest deprecation message.

This commit is contained in:
Jeremy Kemper 2012-05-17 13:17:17 -07:00
parent 0f5cc34ab5
commit 598fc201f9

View file

@ -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]