aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/luajit.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/Library/Formula/luajit.rb b/Library/Formula/luajit.rb
index bead80ba3..6efcc8b95 100644
--- a/Library/Formula/luajit.rb
+++ b/Library/Formula/luajit.rb
@@ -28,4 +28,12 @@ class Luajit < Formula
system 'make', 'amalg', 'install', *args
end
+
+ test do
+ system "#{bin}/luajit", "-e", <<-EOS.strip
+ local ffi = require("ffi")
+ ffi.cdef("int printf(const char *fmt, ...);")
+ ffi.C.printf("Hello %s!\\n", "#{ENV['USER']}")
+ EOS
+ end
end