summaryrefslogtreecommitdiffstats
path: root/run-tests.sh
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2016-08-20 15:19:15 +0200
committerFlorian Pritz <bluewind@xinu.at>2016-08-20 15:19:15 +0200
commit3ce4e928c606f2b3a1c393819ca4a1268e3b058b (patch)
treefbcbadbc18ced14be9bfb3f1b4b553eccda0ae33 /run-tests.sh
parentb7853a87ac0575f83793d5d6a7ed44849156e189 (diff)
tests: Use one webserver per testcase
This allows the tests to run somewhat parallel (still limited by the database) and simplifies running single testcases without the ./run-tests.sh wrapper. Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'run-tests.sh')
-rwxr-xr-xrun-tests.sh13
1 files changed, 1 insertions, 12 deletions
diff --git a/run-tests.sh b/run-tests.sh
index 35a23cbdc..c429acc88 100755
--- a/run-tests.sh
+++ b/run-tests.sh
@@ -6,10 +6,6 @@
export ENVIRONMENT="testsuite"
startdir="$(dirname "$0")"
-url=""
-port=23115
-ip='127.0.0.1'
-url="http://$ip:$port/index.php"
die() {
echo "$@" >&2
@@ -33,19 +29,12 @@ cleanup() {
php index.php tools drop_all_tables
}
-php -S "$ip:$port" -t public_html 2>/dev/null 1>&2 &
-
mkdir -p test-coverage-data
-while ! curl -s "$url" >/dev/null; do
- sleep 0.1;
-done
-
# run tests
phpdbg -qrr index.php tools drop_all_tables || exit 1
phpdbg -qrr index.php tools update_database || exit 1
-prove --ext .php --state=hot,slow,all,save --timer -o -e "phpdbg -qrr index.php tools test $url" -r "$@" application/test/tests/ || exit 1
-
+prove --ext .php --state=hot,slow,all,save --timer -o -e "phpdbg -qrr index.php tools test" -r "$@" application/test/tests/ || exit 1
php index.php tools generate_coverage_report
rm -rf test-coverage-data