aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/camlp4.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/Library/Formula/camlp4.rb b/Library/Formula/camlp4.rb
index 0eb0a7d67..124f97ac4 100644
--- a/Library/Formula/camlp4.rb
+++ b/Library/Formula/camlp4.rb
@@ -1,6 +1,7 @@
require "formula"
class Camlp4 < Formula
+ version '4.02.1+1'
homepage "https://github.com/ocaml/camlp4"
url "https://github.com/ocaml/camlp4/archive/4.02.1+1.tar.gz"
sha1 "7d0f879517887299167f1c3eefa8f4d266d69183"
@@ -17,4 +18,11 @@ class Camlp4 < Formula
system "make", "all"
system "make", "install"
end
+
+ test do
+ (testpath/"foo.ml").write("type t = Homebrew | Rocks")
+ system "#{bin}/camlp4", "-parser", "OCaml", "-printer", "OCamlr", "foo.ml", "-o", (testpath/"foo.ml.out")
+ assert_equal "type t = [ Homebrew | Rocks ];", (testpath/"foo.ml.out").read.strip
+ end
+
end