diff --git a/gen3-integration-tests/conftest.py b/gen3-integration-tests/conftest.py index c6e90d2c8..0e31f0752 100644 --- a/gen3-integration-tests/conftest.py +++ b/gen3-integration-tests/conftest.py @@ -240,7 +240,7 @@ def pytest_runtest_makereport(item): def pytest_unconfigure(config): - if pytest.frontend_url: + if hasattr(pytest, "frontend_url") and pytest.frontend_url: ff_dir = Path(__file__).parent / pytest.frontend_commons_name shutil.rmtree(ff_dir, ignore_errors=True) # Skip running code if --collect-only is passed diff --git a/gen3-integration-tests/gen3_ci/scripts/generate_api_keys.sh b/gen3-integration-tests/gen3_ci/scripts/generate_api_keys.sh index c89ba3f2d..fddb770eb 100755 --- a/gen3-integration-tests/gen3_ci/scripts/generate_api_keys.sh +++ b/gen3-integration-tests/gen3_ci/scripts/generate_api_keys.sh @@ -49,7 +49,9 @@ tail -n +2 "$USERS_FILE" | while IFS="," read -r username email; do fi # Request API key - RESPONSE=$(curl -o "$OUTPUT_DIR/${NAMESPACE}_${username}.json" -w "%{http_code}" -X POST "$HOSTNAME_PROTOCOL://$HOSTNAME/user/credentials/api" \ + ENDPOINT="$HOSTNAME_PROTOCOL://$HOSTNAME/user/credentials/api" + echo "Got access token, now getting API key from '$ENDPOINT'" + RESPONSE=$(curl -o "$OUTPUT_DIR/${NAMESPACE}_${username}.json" -w "%{http_code}" -X POST "$ENDPOINT" \ -H "Authorization: bearer $ACCESS_TOKEN" \ -H "Content-Type: application/json" \ -H "Accept: application/json") diff --git a/gen3-integration-tests/gen3_ci/scripts/prepare_ci_environment.py b/gen3-integration-tests/gen3_ci/scripts/prepare_ci_environment.py index 625a12414..28bf43d7d 100644 --- a/gen3-integration-tests/gen3_ci/scripts/prepare_ci_environment.py +++ b/gen3-integration-tests/gen3_ci/scripts/prepare_ci_environment.py @@ -178,7 +178,7 @@ def modify_env_for_test_repo_pr(namespace): return setup_env_for_helm(arguments) -@retry(times=10, delay=30, exceptions=(Exception)) +@retry(times=6, delay=30, exceptions=(Exception)) def generate_api_keys_for_test_users(): cmd = [ (HELM_SCRIPTS_PATH_OBJECT / "generate_api_keys.sh"),