Add regression test for decf7acced44bb156ba18677f55609b19ff6ca5a
This commit is contained in:
parent
4cbae37d62
commit
9106f221cb
@ -248,4 +248,14 @@ class FormulaTests < Homebrew::TestCase
|
||||
|
||||
assert_equal PkgVersion.parse('HEAD'), f.pkg_version
|
||||
end
|
||||
|
||||
def test_raises_when_non_formula_constant_exists
|
||||
const = :SomeConst
|
||||
Object.const_set(const, Module.new)
|
||||
begin
|
||||
assert_raises(FormulaUnavailableError) { Formulary.factory("some_const") }
|
||||
ensure
|
||||
Object.send(:remove_const, const)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user