[packages/php-pecl-ereg] add test runner script

glen glen at pld-linux.org
Sun Oct 4 17:10:20 CEST 2015


commit 341773060692d6e5223d4459d13844238ecea999
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Sun Oct 4 18:08:31 2015 +0300

    add test runner script

 php-pecl-ereg.spec | 16 ++++++++++++----
 1 file changed, 12 insertions(+), 4 deletions(-)
---
diff --git a/php-pecl-ereg.spec b/php-pecl-ereg.spec
index 1f0bd75..0c0cc35 100644
--- a/php-pecl-ereg.spec
+++ b/php-pecl-ereg.spec
@@ -40,6 +40,16 @@ only.
 %setup -qc
 mv %{modname}-*/* .
 
+cat <<'EOF' > run-tests.sh
+#!/bin/sh
+export NO_INTERACTION=1 REPORT_EXIT_STATUS=1 MALLOC_CHECK_=2
+%{__make} test \
+	PHP_EXECUTABLE=%{__php} \
+	PHP_TEST_SHARED_SYSTEM_EXTENSIONS="" \
+	RUN_TESTS_SETTINGS="-q $*"
+EOF
+chmod +x run-tests.sh
+
 %build
 phpize
 %configure \
@@ -54,10 +64,8 @@ phpize
 	-m > modules.log
 grep %{modname} modules.log
 
-export NO_INTERACTION=1 REPORT_EXIT_STATUS=1 MALLOC_CHECK_=2
-%{__make} test \
-	PHP_EXECUTABLE=%{__php} \
-	PHP_TEST_SHARED_SYSTEM_EXTENSIONS="" \
+./run-tests.sh -w failed.log
+test -f failed.log -a ! -s failed.log
 %endif
 
 %install
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/php-pecl-ereg.git/commitdiff/1fb09c77651a0f52a08d677ad32f815d04e679d8



More information about the pld-cvs-commit mailing list