fix ruby syntax warnings
Closes Homebrew/homebrew#42409. Signed-off-by: Xu Cheng <xucheng@me.com>
This commit is contained in:
parent
1af6ffa950
commit
a5a1cc9865
@ -42,7 +42,7 @@ class VCSDownloadStrategyTests < Homebrew::TestCase
|
|||||||
strategy = Class.new(VCSDownloadStrategy) do
|
strategy = Class.new(VCSDownloadStrategy) do
|
||||||
def cache_tag
|
def cache_tag
|
||||||
"foo"
|
"foo"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
downloader = strategy.new("baz", resource)
|
downloader = strategy.new("baz", resource)
|
||||||
assert_equal HOMEBREW_CACHE.join("baz--foo"), downloader.cached_location
|
assert_equal HOMEBREW_CACHE.join("baz--foo"), downloader.cached_location
|
||||||
|
|||||||
@ -9,7 +9,7 @@ class FormulaValidationTests < Homebrew::TestCase
|
|||||||
|
|
||||||
def test_cant_override_brew
|
def test_cant_override_brew
|
||||||
e = assert_raises(RuntimeError) { formula { def brew; end } }
|
e = assert_raises(RuntimeError) { formula { def brew; end } }
|
||||||
assert_match /You cannot override Formula#brew/, e.message
|
assert_match(/You cannot override Formula#brew/, e.message)
|
||||||
end
|
end
|
||||||
|
|
||||||
def test_validates_name
|
def test_validates_name
|
||||||
|
|||||||
@ -83,7 +83,7 @@ class PatchingTests < Homebrew::TestCase
|
|||||||
assert_patched formula {
|
assert_patched formula {
|
||||||
def patches
|
def patches
|
||||||
{ :p0 => PATCH_URL_B }
|
{ :p0 => PATCH_URL_B }
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -91,7 +91,7 @@ class PatchingTests < Homebrew::TestCase
|
|||||||
assert_patched formula {
|
assert_patched formula {
|
||||||
def patches
|
def patches
|
||||||
[PATCH_URL_A]
|
[PATCH_URL_A]
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -99,7 +99,7 @@ class PatchingTests < Homebrew::TestCase
|
|||||||
assert_patched formula {
|
assert_patched formula {
|
||||||
def patches
|
def patches
|
||||||
{ :p1 => PATCH_URL_A }
|
{ :p1 => PATCH_URL_A }
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -107,7 +107,7 @@ class PatchingTests < Homebrew::TestCase
|
|||||||
assert_patched formula {
|
assert_patched formula {
|
||||||
def patches
|
def patches
|
||||||
{ :p1 => [PATCH_URL_A] }
|
{ :p1 => [PATCH_URL_A] }
|
||||||
end
|
end
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user