mpfr: add test

This commit is contained in:
Xu Cheng 2014-12-28 22:39:26 +08:00 committed by Mike McQuaid
parent 40c173f4a6
commit 01974f4b9e

View file

@ -39,4 +39,21 @@ class Mpfr < Formula
system "make", "check"
system "make", "install"
end
test do
(testpath/"test.c").write <<-EOS.undent
#include <gmp.h>
#include <mpfr.h>
int main()
{
mpfr_t x;
mpfr_init(x);
mpfr_clear(x);
return 0;
}
EOS
system ENV.cc, "test.c", "-lgmp", "-lmpfr", "-o", "test"
system "./test"
end
end