]> git.pld-linux.org Git - packages/mksh.git/commitdiff
- skip some tests if not run with a terminal
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Thu, 7 Jul 2011 20:55:39 +0000 (20:55 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    mksh.spec -> 1.22

mksh.spec

index 3f5be0949db66b5f2d0bf6ee67f24efa25b18ad3..d5eba4e6a53634a4c8d8be5474c760f7e0a50130 100644 (file)
--- a/mksh.spec
+++ b/mksh.spec
@@ -93,7 +93,16 @@ CFLAGS="%{rpmcppflags} %{rpmcflags}" \
 LDFLAGS="%{rpmldflags}" \
 sh ./Build.sh -Q -r -j
 
-%{?with_tests:./test.sh -v}
+# skip some tests if not on terminal
+if ! tty -s; then
+do_tests=$(awk '
+/^---/ { if (need_ctty == 0) { print name; }; need_ctty=0; }
+/^name:/ { name=$2; }
+/^need-ctty:/ { need_ctty=1; }
+' check.t)
+fi
+
+%{?with_tests:./test.sh -v $do_tests}
 mv mksh out/mksh.dynamic
 
 %if %{with static}
@@ -102,7 +111,7 @@ CFLAGS="%{rpmcppflags} %{rpmcflags}" \
 LDFLAGS="%{rpmldflags} -static" \
 sh ./Build.sh -Q -r -j
 
-%{?with_tests:./test.sh -v}
+%{?with_tests:./test.sh -v $do_tests}
 mv mksh out/mksh.static
 %endif
 
This page took 0.076348 seconds and 4 git commands to generate.