test_formula: fix tests
New name and old name must have different names
This commit is contained in:
parent
0ae1785703
commit
4ec43d02f5
@ -799,8 +799,8 @@ end
|
|||||||
class AliasChangeTests < Homebrew::TestCase
|
class AliasChangeTests < Homebrew::TestCase
|
||||||
attr_reader :f, :new_formula, :tab, :alias_path
|
attr_reader :f, :new_formula, :tab, :alias_path
|
||||||
|
|
||||||
def make_formula(version)
|
def make_formula(name, version)
|
||||||
f = formula(alias_path: alias_path) { url "foo-#{version}" }
|
f = formula(name, alias_path: alias_path) { url "foo-#{version}" }
|
||||||
f.build = tab
|
f.build = tab
|
||||||
f
|
f
|
||||||
end
|
end
|
||||||
@ -811,8 +811,8 @@ class AliasChangeTests < Homebrew::TestCase
|
|||||||
|
|
||||||
@tab = Tab.empty
|
@tab = Tab.empty
|
||||||
|
|
||||||
@f = make_formula("1.0")
|
@f = make_formula("formula_name", "1.0")
|
||||||
@new_formula = make_formula("1.1")
|
@new_formula = make_formula("new_formula_name", "1.1")
|
||||||
|
|
||||||
Formula.stubs(:installed).returns([f])
|
Formula.stubs(:installed).returns([f])
|
||||||
end
|
end
|
||||||
|
Loading…
x
Reference in New Issue
Block a user