[packages/php-pecl-solr] run bundled testsuite

glen glen at pld-linux.org
Thu May 14 15:44:06 CEST 2015


commit de2189f23d92e7d181824dc660d6b581f76e20db
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Thu May 14 16:15:07 2015 +0300

    run bundled testsuite

 php-pecl-solr.spec |  7 +++++++
 tests.patch        | 10 ++++++++++
 2 files changed, 17 insertions(+)
---
diff --git a/php-pecl-solr.spec b/php-pecl-solr.spec
index e45dc23..8956b96 100644
--- a/php-pecl-solr.spec
+++ b/php-pecl-solr.spec
@@ -13,6 +13,7 @@ License:	PHP v3.01
 Group:		Development/Languages
 Source0:	http://pecl.php.net/get/%{modname}-%{version}.tgz
 # Source0-md5:	258865d4517312afda6890827f18f93f
+Patch0:		tests.patch
 URL:		http://pecl.php.net/package/solr
 BuildRequires:	%{php_name}-devel >= 4:5.2.3
 BuildRequires:	curl-devel
@@ -77,6 +78,7 @@ possible de se connecter à des serveurs via SSL.
 %prep
 %setup -qc
 mv %{modname}-%{version}/* .
+%patch0 -p1
 
 %build
 packagexml2cl package.xml > ChangeLog
@@ -100,6 +102,11 @@ phpize
 	-d extension=%{modname}.so \
 	-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="json" \
 %endif
 
 %install
diff --git a/tests.patch b/tests.patch
new file mode 100644
index 0000000..d2db22d
--- /dev/null
+++ b/tests.patch
@@ -0,0 +1,10 @@
+--- php55-pecl-solr-2.1.0/tests/test.config.inc~	2015-01-17 17:40:05.000000000 +0200
++++ php55-pecl-solr-2.1.0/tests/test.config.inc	2015-05-14 16:13:44.177230625 +0300
+@@ -1,6 +1,6 @@
+ <?php
+ 
+-define('SOLR_SERVER_CONFIGURED', true);
++define('SOLR_SERVER_CONFIGURED', !!getenv("SOLR_SERVER_CONFIGURED"));
+ 
+ define('ROOT_DIRECTORY', dirname(__FILE__));
+ 
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/php-pecl-solr.git/commitdiff/026132b40dee1a95efa90e3d4cfabfc070e59f9f



More information about the pld-cvs-commit mailing list