Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#!/usr/bin/env bash
cd `dirname $0`
source ./.env
while getopts "u:p:h:d:ct:z:s:vkge:" ARG
do
case ${ARG} in
e) TEST_ENV=$OPTARG;;
esac
done
TEST_ENV=${TEST_ENV-""}
RUN_WITH=""
RUN_CHROME=`echo "${TEST_ENV}" | sed 's/chrome//'`
if [ "${TEST_ENV}" != "${RUN_CHROME}" ]
then
RUN_WITH="${RUN_WITH}-chrome "
fi
RUN_FIREFOX=`echo "${TEST_ENV}" | sed 's/firefox//'`
if [ "${TEST_ENV}" != "${RUN_FIREFOX}" ]
then
RUN_WITH="${RUN_WITH}-firefox "
fi
RUN_PHANTOMJS=`echo "${TEST_ENV}" | sed 's/phantomjs//'`
if [ "${TEST_ENV}" != "${RUN_PHANTOMJS}" ]
then
RUN_WITH="${RUN_WITH}-phantomjs "
fi
for BROWSER in "${RUN_WITH}"
do
docker-compose run --rm acceptance-tests${BROWSER} $@
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.