summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bindings/php5/Makefile.am2
-rw-r--r--bindings/php5/tests/Makefile.am1
-rwxr-xr-xbindings/php5/tests/binding_tests.php2
-rwxr-xr-xbindings/php5/tests/binding_tests.sh2
-rwxr-xr-xbindings/php5/tests/profile_tests.php2
-rwxr-xr-xbindings/php5/tests/profile_tests.sh2
-rw-r--r--configure.ac1
7 files changed, 7 insertions, 5 deletions
diff --git a/bindings/php5/Makefile.am b/bindings/php5/Makefile.am
index 4ba2965c..9c144242 100644
--- a/bindings/php5/Makefile.am
+++ b/bindings/php5/Makefile.am
@@ -1,6 +1,6 @@
MAINTAINERCLEANFILES = Makefile.in
MOSTLYCLEANFILES = __init__.pyc lang.pyc php_code.pyc wrapper_header.pyc wrapper_top.pyc
-SUBDIRS = examples
+SUBDIRS = examples tests
INCLUDES = \
-I$(top_builddir) \
diff --git a/bindings/php5/tests/Makefile.am b/bindings/php5/tests/Makefile.am
index 9b2a353d..b2d8549e 100644
--- a/bindings/php5/tests/Makefile.am
+++ b/bindings/php5/tests/Makefile.am
@@ -1,5 +1,6 @@
MAINTAINERCLEANFILES = Makefile.in
if PHP5_ENABLED
+TESTS_ENVIRONMENT=env "SRCDIR=$(srcdir)/"
TESTS = profile_tests.sh binding_tests.sh
endif
diff --git a/bindings/php5/tests/binding_tests.php b/bindings/php5/tests/binding_tests.php
index 4c9fb962..e7b89abf 100755
--- a/bindings/php5/tests/binding_tests.php
+++ b/bindings/php5/tests/binding_tests.php
@@ -23,7 +23,7 @@
require("../lasso.php");
-define("DATA_DIR", "../../../tests/data/");
+define("DATA_DIR", getenv("SRCDIR") . "../../../tests/data/");
function test01() {
echo "Get an xmlNode* from a Lasso function... ";
diff --git a/bindings/php5/tests/binding_tests.sh b/bindings/php5/tests/binding_tests.sh
index 9f3e9e17..3bfad5d6 100755
--- a/bindings/php5/tests/binding_tests.sh
+++ b/bindings/php5/tests/binding_tests.sh
@@ -1,3 +1,3 @@
#!/bin/sh
-php5 -n -d extension_dir=../.libs binding_tests.php
+php5 -n -d extension_dir=../.libs -d extension=lasso.so ${SRCDIR}binding_tests.php
diff --git a/bindings/php5/tests/profile_tests.php b/bindings/php5/tests/profile_tests.php
index 50264330..58414213 100755
--- a/bindings/php5/tests/profile_tests.php
+++ b/bindings/php5/tests/profile_tests.php
@@ -23,7 +23,7 @@
require("../lasso.php");
-define("DATA_DIR", "../../../tests/data/");
+define(DATA_DIR, getenv('SRCDIR') . '../../../tests/data/');
function test01() {
echo "Server construction, dump & newFromDump... ";
diff --git a/bindings/php5/tests/profile_tests.sh b/bindings/php5/tests/profile_tests.sh
index 446131df..08a53fac 100755
--- a/bindings/php5/tests/profile_tests.sh
+++ b/bindings/php5/tests/profile_tests.sh
@@ -1,3 +1,3 @@
#!/bin/sh
-php5 -n -d extension_dir=../.libs profile_tests.php
+php5 -n -d extension_dir=../.libs -d extension=lasso.so ${SRCDIR}profile_tests.php
diff --git a/configure.ac b/configure.ac
index ebc6ce8e..906d7d82 100644
--- a/configure.ac
+++ b/configure.ac
@@ -946,6 +946,7 @@ bindings/python/Makefile
bindings/python/tests/Makefile
bindings/php5/Makefile
bindings/php5/examples/Makefile
+bindings/php5/tests/Makefile
])
languages_available=`echo $languages_available | sed -e "s/^ //" `