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

Update base_url in test if content_origin is null #1118

Merged
merged 1 commit into from
Jan 20, 2025
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
7 changes: 7 additions & 0 deletions tests/scripts/pulp_file/test_distribution.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,13 @@ fi
expect_succ pulp file distribution list --base-path "cli_test_file_distro"
test "$(echo "$OUTPUT" | jq -r length)" -eq 1
base_url="$(echo "$OUTPUT" | jq -r .[0].base_url)"

# if base_url starts with "/" (relative path) we need to prepend it with the server address
if [[ $base_url == /* ]]
then
base_url="http://localhost:8080${base_url}"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's probably better to use the base url from the config instead of a hardcoded address here.
OTOH, we are not testing the cli with it. We should just remove this part.

fi

expect_succ pulp file distribution list --base-path-contains "CLI"
test "$(echo "$OUTPUT" | jq -r length)" -gt 0

Expand Down
Loading