Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow ftrepo to accept custom browser path running integTest #678

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions integtest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -85,13 +85,20 @@ then
PASSWORD=`echo $CREDENTIAL | awk -F ':' '{print $2}'`
fi

# User can send custom browser path through env variable
if [ -z "$BROWSER_PATH" ]
then
BROWSER_PATH="chromium"
fi

. ./test_finder.sh

npm install

TEST_FILES=`get_test_list $TEST_COMPONENTS`
echo -e "Test Files List:"
echo $TEST_FILES | tr ',' '\n'
echo "BROWSER_PATH: $BROWSER_PATH"

## WARNING: THIS LOGIC NEEDS TO BE THE LAST IN THIS FILE! ##
# Cypress returns back the test failure count in the error code
Expand All @@ -102,8 +109,8 @@ echo $TEST_FILES | tr ',' '\n'
if [ $SECURITY_ENABLED = "true" ]
then
echo "run security enabled tests"
yarn cypress:run-with-security --browser chromium --spec "$TEST_FILES"
yarn cypress:run-with-security --browser "$BROWSER_PATH" --spec "$TEST_FILES"
else
echo "run security disabled tests"
yarn cypress:run-without-security --browser chromium --spec "$TEST_FILES"
yarn cypress:run-without-security --browser "$BROWSER_PATH" --spec "$TEST_FILES"
fi