-
Notifications
You must be signed in to change notification settings - Fork 114
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
Add tests for ansible-tower/AAP integration with Satellite #16555
base: master
Are you sure you want to change the base?
Add tests for ansible-tower/AAP integration with Satellite #16555
Conversation
0cbcaed
to
9788041
Compare
8158669
to
41af678
Compare
trigger: test-robottelo |
PRT Result
|
Signed-off-by: Gaurav Talreja <[email protected]>
41af678
to
dd8b2d1
Compare
trigger: test-robottelo |
PRT Result
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is super cool and i am excited to see the scenario with the on-premise provisioning. I think we could clean this up a bit by moving the most of the stuff to the fixtures so only the bits relevant to the test scenarios remain, but overall, I really like how well readable this is. Great job!
oh and btw, let's get rid of those static timeouts, unless there is a good reason for not using wait-for
. Would that make sense?
|
||
password = settings.server.admin_password | ||
if auth_type == 'admin': | ||
login = gen_string('alpha') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this feels like something that belongs to the setup
phase rather to the body of the test. Could we possible move this to a fixture that would accept role
as a parameter and request it by test by passing it the value of auth_type
indirectly?
host.update(['location']) | ||
|
||
# Find the Satellite credentials in AAP and update it for target_sat.hostname and user credentials | ||
creds_list = aap_client.get( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one looks like another candidate for a fixture. I see you use the same code in the other test too.
f'/api/v2/inventory_sources/{inv_source_list["results"][0]["id"]}/update/' | ||
) | ||
assert sync_response.ok | ||
sleep(180) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see you imported wait-for
lib. Why not use it here? Use of static timeouts is discouraged.
assert rhel_contenthost.hostname in [host['name'] for host in hosts_list['results']] | ||
|
||
@pytest.mark.on_premises_provisioning | ||
@pytest.mark.parametrize('pxe_loader', ['bios', 'uefi'], indirect=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this something where the choice of bootloader actually matters?
are the callback parameters passed to installer via pxelinux or grub cfg, or are they pulled via http by installer later in the process?
if the latter, we could probably drop one of these and stick to a single scenario. If not, then sorry for interruption, resolve my comment and carry on ;)
PRT Result
|
Problem Statement
Missing test coverage for ansible-tower/AAP integration with Satellite
Solution
Add tests for ansible-tower/AAP integration with Satellite
Related Issues