newt: add test
Closes #3284. Signed-off-by: Tim D. Smith <git@tim-smith.us>
This commit is contained in:
parent
390421b0f3
commit
a1c8897851
1 changed files with 14 additions and 0 deletions
|
@ -43,4 +43,18 @@ class Newt < Formula
|
|||
system "./configure", *args
|
||||
system "make", "install"
|
||||
end
|
||||
|
||||
test do
|
||||
ENV["TERM"] = "xterm"
|
||||
system "python", "-c", "import snack"
|
||||
(testpath/"test.c").write <<-EOS.undent
|
||||
#import <newt.h>
|
||||
int main() {
|
||||
newtInit();
|
||||
newtFinished();
|
||||
}
|
||||
EOS
|
||||
system ENV.cc, testpath/"test.c", "-o", testpath/"newt_test", "-lnewt"
|
||||
system testpath/"newt_test"
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue