aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/test_formula_validation.rb
diff options
context:
space:
mode:
authorJack Nagel2013-04-13 17:40:14 -0500
committerJack Nagel2013-04-13 17:40:14 -0500
commit6f252fe1d2eaf33cfe2302f0844d0a7eadd56918 (patch)
tree6416659a483a4def574bff7651af4c26828e24fb /Library/Homebrew/test/test_formula_validation.rb
parentd78efa8f02936b9bfc7da344f18351ce00eed936 (diff)
downloadhomebrew-6f252fe1d2eaf33cfe2302f0844d0a7eadd56918.tar.bz2
Raise a useful exception for incomplete formulae
Diffstat (limited to 'Library/Homebrew/test/test_formula_validation.rb')
-rw-r--r--Library/Homebrew/test/test_formula_validation.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/Library/Homebrew/test/test_formula_validation.rb b/Library/Homebrew/test/test_formula_validation.rb
index 5c6bf2888..22b0eb06c 100644
--- a/Library/Homebrew/test/test_formula_validation.rb
+++ b/Library/Homebrew/test/test_formula_validation.rb
@@ -77,4 +77,9 @@ class FormulaValidationTests < Test::Unit::TestCase
end
end
end
+
+ def test_empty_formula_invalid
+ e = assert_raises(RuntimeError) { formula {} }
+ assert_equal "Formulae require at least a URL", e.message
+ end
end