Skip to content

Commit

Permalink
Fixed tests that break in domain-enabled environments.
Browse files Browse the repository at this point in the history
fixes pulp#692.
  • Loading branch information
ggainey committed May 18, 2023
1 parent 82d9ba7 commit 0e973ab
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions CHANGES/692.bugfix
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Fixed some tests that made assumptions that worked, but were nonetheless incorrect.

2 changes: 1 addition & 1 deletion tests/scripts/pulp_file/test_acs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ test "$(echo "$OUTPUT" | jq ".paths | length")" -eq 2

# test refresh
expect_succ pulp --background file acs refresh --acs $acs
task_group=$(echo "$ERROUTPUT" | grep -E -o "${PULP_API_ROOT}([-_a-zA-Z0-9]+/)?api/v3/task-groups/[-[:xdigit:]]*/")
task_group=$(echo "$ERROUTPUT" | grep -E -o "/.*/api/v3/task-groups/[-[:xdigit:]]*/")
expect_succ pulp task-group show --href "$task_group" --wait

group_task_uuid="${task_group%/}"
Expand Down
2 changes: 1 addition & 1 deletion tests/scripts/pulp_rpm/test_acs.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ test "$(echo "$OUTPUT" | jq ".paths | length")" -eq 2

# test refresh
expect_succ pulp rpm acs refresh --acs $acs
task_group=$(echo "$ERROUTPUT" | grep -E -o "${PULP_API_ROOT}api/v3/task-groups/[-[:xdigit:]]*/")
task_group=$(echo "$ERROUTPUT" | grep -E -o "/.*/api/v3/task-groups/[-[:xdigit:]]*/")
expect_succ pulp task-group show --href "$task_group"
test "$(echo "$OUTPUT" | jq ".tasks | length")" -eq 2

Expand Down
4 changes: 2 additions & 2 deletions tests/scripts/pulp_rpm/test_rpm_sync_publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ PUBLICATION_VER_HREF=$(echo "$OUTPUT" | jq -r .pulp_href)
expect_succ pulp rpm distribution create --name "cli_test_rpm_distro" \
--base-path "cli_test_rpm_distro" \
--publication "$PUBLICATION_HREF"

expect_succ curl "$curl_opt" --head --fail "$PULP_BASE_URL/pulp/content/cli_test_rpm_distro/config.repo"
DISTRIBUTION_BASE_URL=$(echo "$OUTPUT" | jq -r .base_url)
expect_succ curl "$curl_opt" --head --fail "${DISTRIBUTION_BASE_URL}config.repo"

expect_succ pulp rpm repository version list --repository "cli_test_rpm_repository"
expect_succ pulp rpm repository version repair --repository "cli_test_rpm_repository" --version 1
Expand Down

0 comments on commit 0e973ab

Please sign in to comment.