Skip to content

Commit

Permalink
[6.15.z] small fix related to repo sync bulk canceled scenario (#13952)
Browse files Browse the repository at this point in the history
  • Loading branch information
Satellite-QE authored Jan 31, 2024
1 parent aaea068 commit 683836a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/foreman/api/test_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -1406,7 +1406,7 @@ def test_positive_bulk_cancel_sync(self, target_sat, module_entitlement_manifest
time.sleep(30)
target_sat.api.ForemanTask().bulk_cancel(data={"task_ids": sync_ids[5:]})
for sync_id in sync_ids:
sync_result = target_sat.api.ForemanTask(id=sync_id).poll(canceled=True)
sync_result = target_sat.api.ForemanTask(id=sync_id).poll(must_succeed=False)
assert (
'Task canceled' in sync_result['humanized']['errors']
or 'No content added' in sync_result['humanized']['output']
Expand Down Expand Up @@ -1667,7 +1667,7 @@ def test_positive_cancel_docker_repo_sync(self, repo, target_sat):
# Need to wait for sync to actually start up
time.sleep(2)
target_sat.api.ForemanTask().bulk_cancel(data={"task_ids": [sync_task['id']]})
sync_task = target_sat.api.ForemanTask(id=sync_task['id']).poll(canceled=True)
sync_task = target_sat.api.ForemanTask(id=sync_task['id']).poll(must_succeed=False)
assert 'Task canceled' in sync_task['humanized']['errors']
assert 'No content added' in sync_task['humanized']['output']

Expand Down

0 comments on commit 683836a

Please sign in to comment.