Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/phpmyadmin/phpmyadmin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Desportes <williamdes@wdes.fr>2020-05-25 00:13:09 +0300
committerWilliam Desportes <williamdes@wdes.fr>2020-06-10 02:27:22 +0300
commit4de5bcb2a7d65ee9e12d14b50b4750dbec40634f (patch)
treea9854a73f215ad18ca6109b636464009eca9b8d8 /test/stop-local-server
parent28dc4088130cf10d021eefd163ad534ef756fe88 (diff)
Support selenium-standalone mode and use docker
Signed-off-by: William Desportes <williamdes@wdes.fr>
Diffstat (limited to 'test/stop-local-server')
-rwxr-xr-xtest/stop-local-server26
1 files changed, 26 insertions, 0 deletions
diff --git a/test/stop-local-server b/test/stop-local-server
new file mode 100755
index 0000000000..f187848f97
--- /dev/null
+++ b/test/stop-local-server
@@ -0,0 +1,26 @@
+#!/bin/sh
+
+# Do not run as CGI
+if [ -n "$GATEWAY_INTERFACE" ] ; then
+ echo 'Can not invoke as CGI!'
+ exit 1
+fi
+
+set -e
+set -x
+
+if [ "$CI_MODE" != "selenium" ] ; then
+ echo "Not in CI_MODE=selenium"
+ exit 0
+fi
+
+if [ ! -z "$TESTSUITE_BROWSERSTACK_KEY" ] ; then
+ # Stop BrowserStack Local forwarder
+ ~/browserstack/BrowserStackLocal --daemon stop
+fi
+
+if [ -f ~/selenium-standalone.pid~ ] ; then
+ # Stop selenium-standalone server
+ kill $(cat ~/selenium-standalone.pid~)
+ rm ~/selenium-standalone.pid~
+fi