check: added test to formula
Closes #10369. Signed-off-by: Tomasz Pajor <tomek@polishgeeks.com>
This commit is contained in:
parent
bea0ebe3f1
commit
5f05fdfdf1
1 changed files with 12 additions and 0 deletions
|
@ -18,4 +18,16 @@ class Check < Formula
|
|||
"--prefix=#{prefix}"
|
||||
system "make", "install"
|
||||
end
|
||||
|
||||
test do
|
||||
(testpath/"test.tc").write <<-EOS.undent
|
||||
#test test1
|
||||
ck_assert_msg(1, "This should always pass");
|
||||
EOS
|
||||
|
||||
system "#{bin/"checkmk"} test.tc > test.c"
|
||||
|
||||
system ENV.cc, "test.c", "-I#{include}", "-L#{lib}", "-lcheck", "-o", "test"
|
||||
system "./test"
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue