4040from robottelo .exceptions import CLIReturnCodeError
4141from robottelo .hosts import ContentHost
4242from robottelo .utils .datafactory import parametrized
43+ from robottelo .utils .issue_handlers import is_open
4344
4445
4546def valid_name_desc_data ():
@@ -363,7 +364,7 @@ def test_positive_update_console_password(set_console_password, module_target_sa
363364@pytest .mark .e2e
364365@pytest .mark .on_premises_provisioning
365366@pytest .mark .rhel_ver_match ('[7]' )
366- @pytest .mark .parametrize ('pxe_loader' , ['uefi' , 'secureboot' ], indirect = True )
367+ @pytest .mark .parametrize ('pxe_loader' , ['bios' , ' uefi' , 'secureboot' ], indirect = True )
367368@pytest .mark .parametrize ('setting_update' , ['destroy_vm_on_host_delete=True' ], indirect = True )
368369@pytest .mark .parametrize ('libvirt' , ['libvirt9' , 'libvirt10' ], indirect = True )
369370def test_positive_provision_end_to_end (
@@ -376,6 +377,7 @@ def test_positive_provision_end_to_end(
376377 module_location ,
377378 provisioning_hostgroup ,
378379 module_provisioning_rhel_content ,
380+ module_restart_dhcpd ,
379381):
380382 """Provision a host on Libvirt compute resource with the help of hostgroup.
381383
@@ -400,6 +402,10 @@ def test_positive_provision_end_to_end(
400402
401403 :customerscenario: true
402404 """
405+ # Skip test for UEFI and SecureBoot loaders
406+ if is_open ('SAT-41340' ) and pxe_loader .vm_firmware in ['uefi' , 'uefi_secure_boot' ]:
407+ pytest .skip (f"Test not supported for { pxe_loader .vm_firmware } firmware" )
408+
403409 sat = module_libvirt_provisioning_sat .sat
404410 cr_name = gen_string ('alpha' )
405411 hostname = gen_string ('alpha' ).lower ()
@@ -442,12 +448,16 @@ def test_positive_provision_end_to_end(
442448 f'su foreman -s /bin/bash -c "virsh -c { libvirt .url } list --state-running"'
443449 )
444450 assert hostname in result .stdout
445-
446451 wait_for (
447- lambda : sat .cli .Host .info ({'name' : hostname })['status' ]['build-status' ]
448- != 'Pending installation' ,
452+ lambda : (
453+ sat .cli .Host .info ({'name' : hostname })
454+ .get ('status' , {})
455+ .get ('build-status' , 'Pending installation' )
456+ != 'Pending installation'
457+ ),
449458 timeout = 1800 ,
450459 delay = 30 ,
460+ handle_exception = True ,
451461 )
452462 host_info = sat .cli .Host .info ({'id' : host ['id' ]})
453463 assert host_info ['status' ]['build-status' ] == 'Installed'
0 commit comments