4 if [ -n "$GATEWAY_INTERFACE" ] ; then
5 echo 'Can not invoke as CGI!'
12 if [ "$CI_MODE" != "selenium" ] ; then
13 echo "Not in CI_MODE=selenium"
17 # Start php-fpm + nginx in temporary dir
18 DIR
=`mktemp -d --suffix=-phpMyAdminTest`
21 # Create configuration with correct paths
22 cp test
/nginx.conf test
/php-fpm.conf test
/php.ini
$DIR/
23 sed -i -e "s,%DIR%,$DIR," -e "s,%ROOT%,$CURRENT," $DIR/*
26 echo "Using temporary dir: ${DIR}"
28 # You can define FPM_PATH to override the path for example FPM_PATH="php-fpm7.4"
29 FPM_PATH
="${FPM_PATH:-php-fpm}"
30 if [ ! -z "${TRAVIS}" ]; then
31 PHP_VERSION
=$
(phpenv version-name
)
32 FPM_PATH
="$HOME/.phpenv/versions/$PHP_VERSION/sbin/php-fpm"
36 "$FPM_PATH" --fpm-config $DIR/php-fpm.conf
-c $DIR/php.ini
37 ${NGINX_PATH:-nginx} -c $DIR/nginx.conf
39 if [ ! -z "$TESTSUITE_BROWSERSTACK_KEY" ] ; then
40 echo "Using: BrowserStack"
41 # Install if necessary
42 if [ ! -f ~
/browserstack
/BrowserStackLocal
] ; then
43 mkdir
-p ~
/browserstack
45 wget https
://www.browserstack.com
/browserstack-local
/BrowserStackLocal-linux-x64.
zip
46 unzip BrowserStackLocal-linux-x64.
zip
48 # Start BrowserStack Local forwarder
49 ~
/browserstack
/BrowserStackLocal
--force-local --localIdentifier "travis-$TRAVIS_JOB_NUMBER" --onlyAutomate --key "$TESTSUITE_BROWSERSTACK_KEY" --daemon start
50 elif [ -z "$SKIP_STANDALONE" ] ; then
51 echo "Using: selenium-standalone"
52 if [ ! -f selenium-standalone
]; then
53 yarn global add selenium-standalone
54 selenium-standalone
install
56 selenium-standalone start
-- -debug > ~
/selenium-standalone.logs~
2>&1 &
57 echo $
! > ~
/selenium-standalone.pid~
59 echo "Using: nothing."