mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Add parenthesis to avoid syntax warnings.
This commit is contained in:
parent
059d609a1a
commit
9027721b11
2 changed files with 2 additions and 2 deletions
|
@ -71,7 +71,7 @@ class PrototypeHelperBaseTest < ActionView::TestCase
|
|||
end
|
||||
|
||||
def create_generator
|
||||
block = Proc.new { |*args| yield *args if block_given? }
|
||||
block = Proc.new { |*args| yield(*args) if block_given? }
|
||||
JavaScriptGenerator.new self, &block
|
||||
end
|
||||
end
|
||||
|
|
|
@ -103,7 +103,7 @@ class TagHelperTest < ActionView::TestCase
|
|||
|
||||
def test_skip_invalid_escaped_attributes
|
||||
['&1;', 'dfa3;', '& #123;'].each do |escaped|
|
||||
assert_equal %(<a href="#{escaped.gsub /&/, '&'}" />), tag('a', :href => escaped)
|
||||
assert_equal %(<a href="#{escaped.gsub(/&/, '&')}" />), tag('a', :href => escaped)
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue