Skip to content

Commit 64bfae4

Browse files
Fix local execution of tests
It was failing because it could not resolve an env var
1 parent ded629c commit 64bfae4

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

selenium/bin/gen-env-file

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11
#!/usr/bin/env bash
22
SCRIPT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
33

4-
#set -x
4+
if [[ ! -z "${DEBUG}" ]]; then
5+
set -x
6+
fi
7+
58

69
ENV_FILE="/tmp/rabbitmq/.env"
710
FIND_PATH=$1
@@ -14,6 +17,7 @@ generate_env_file() {
1417
echo "#!/usr/bin/env bash" > $ENV_FILE
1518
echo "set -u" >> $ENV_FILE
1619
echo "export SELENIUM=${SCRIPT}/.." >> $ENV_FILE
20+
echo "export TEST_CONFIG_PATH=${TEST_CONFIG_PATH}" >> $ENV_FILE
1721

1822
declare -a FILE_ARRAY
1923
for f in $($SCRIPT/find-template-files $FIND_PATH "env")

selenium/bin/suite_template

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -374,8 +374,7 @@ generate_env_file() {
374374
begin "Generating env file ..."
375375
mkdir -p $CONF_DIR
376376
${BIN_DIR}/gen-env-file $TEST_CONFIG_DIR $ENV_FILE
377-
source $ENV_FILE
378-
echo "export TEST_CONFIG_PATH=${TEST_CONFIG_PATH}" >> $ENV_FILE
377+
source $ENV_FILE
379378
end "Finished generating env file."
380379
}
381380
generate-ca-server-client-kpi() {

0 commit comments

Comments
 (0)