Skip to content

Commit

Permalink
Tweak test bash script
Browse files Browse the repository at this point in the history
  • Loading branch information
mbardelmeijer committed Dec 4, 2021
1 parent 97f251c commit fc2e495
Showing 1 changed file with 17 additions and 3 deletions.
20 changes: 17 additions & 3 deletions tests.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,24 @@
trap cleanup INT TERM
killall soffice.bin
killall unoserver

cleanup() {
killall unoserver
exit
}
trap cleanup INT TERM

unoserver &

unoserver --daemon
sleep 1
echo -e "Waiting for unoserver to start..."

while ! nc -z 127.0.0.1 2002; do
echo -n "."
sleep 0.1 # wait for 1/10 of the second before check again
done

echo -e "Running tests"
vendor/bin/phpunit

killall unoserver

exit $?

0 comments on commit fc2e495

Please sign in to comment.