Skip to content

Commit

Permalink
Add MULLVAD_HOST setting to test-by-version.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
dlon committed Nov 15, 2024
1 parent ac72c93 commit b3aecca
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions test/scripts/test-utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,12 @@ function run_tests_for_os {
runner_dir_flag=()
fi

if [ -n "${MULLVAD_HOST+x}" ]; then
mullvad_host_arg=("--mullvad-host" "$MULLVAD_HOST")
else
mullvad_host_arg=()
fi

if ! RUST_LOG_STYLE=always $test_manager run-tests \
--account "${ACCOUNT_TOKEN:?Error: ACCOUNT_TOKEN not set}" \
--app-package "${APP_PACKAGE:?Error: APP_PACKAGE not set}" \
Expand All @@ -301,6 +307,7 @@ function run_tests_for_os {
--package-dir "${package_dir}" \
--vm "$vm" \
--openvpn-certificate "${OPENVPN_CERTIFICATE:-"assets/openvpn.ca.crt"}" \
"${mullvad_host_arg[@]}" \
"${test_filters_arg[@]}" \
"${runner_dir_flag[@]}" \
2>&1 | sed -r "s/${ACCOUNT_TOKEN}/\{ACCOUNT_TOKEN\}/g"; then
Expand Down
1 change: 1 addition & 0 deletions test/test-by-version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ usage() {
echo " - APP_VERSION: The version of the app to test (defaults to the latest stable release)"
echo " - APP_PACKAGE_TO_UPGRADE_FROM: The package version to upgrade from (defaults to none)"
echo " - OPENVPN_CERTIFICATE: Path to an OpenVPN CA certificate the app should use during test (defaults to assets/openvpn.ca.crt)"
echo " - MULLVAD_HOST: Conncheck and API environment to use, eg stagemole.eu (defaults to mullvad.net, or the config file if set)"
echo " - TEST_DIST_DIR: Relative path to a directory with prebuilt binaries as produced by scripts/build.sh."
echo " - TEST_FILTERS: specifies which tests to run (defaults to all)"
echo " - TEST_REPORT : path to save the test results in a structured format"
Expand Down

0 comments on commit b3aecca

Please sign in to comment.