Skip to content

Fix failing pinned sliced host test#585

Merged
cigamit merged 1 commit into
mainfrom
test-fixes-260717
Jul 17, 2026
Merged

Fix failing pinned sliced host test#585
cigamit merged 1 commit into
mainfrom
test-fixes-260717

Conversation

@cigamit

@cigamit cigamit commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Test is currently failing for the new pinned sliced host feature, even though it didn't appear to fail before merging the original feature. Simple fix.

@cigamit
cigamit requested a review from TheWitness July 17, 2026 20:32
@cigamit cigamit self-assigned this Jul 17, 2026
Copilot AI review requested due to automatic review settings July 17, 2026 20:32
@cigamit cigamit added bug Something isn't working python Pull requests that update python code labels Jul 17, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR adjusts unit tests for the job fact-cache pre/post hooks to account for the new pinned sliced host behavior, ensuring the tests don’t fail due to MagicMock(spec=Job) returning a truthy mock for the job_slice_pinned_hosts_list property.

Changes:

  • Explicitly sets job.job_slice_pinned_hosts_list = [] in two unit tests so host slicing logic receives an empty/falsey pinned-hosts value.

Comment thread awx/main/tests/unit/tasks/test_jobs.py
Comment thread awx/main/tests/unit/tasks/test_jobs.py
@cigamit
cigamit merged commit 336db7b into main Jul 17, 2026
1 check passed
@cigamit
cigamit deleted the test-fixes-260717 branch July 17, 2026 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working python Pull requests that update python code

Development

Successfully merging this pull request may close these issues.

3 participants