WIP: Test multiple boot interfaces as part of one CI job

The idea here came out of the 2024.1 PTG held in ?October? 2023,
with the goal of being able to exercise testing of boot interfaces
as a group in a single job, instead of spreading it out amongst
CI jobs with different scenarios.

That doesn't mean different scenarios are wrong, but as we add more
boot interfaces as part of supporting HTTPBoot, we cannot double
our scenarios.

In theory, the hope is we should be able to consolidate down several
secenario jobs into just one test running these jobs.

Change-Id: Id41ee40c36624387216b2cfc1501f01a3217b2af
This commit is contained in:
Julia Kreger 2023-11-29 08:40:30 -08:00
parent caae7cc6ec
commit 3a32f1c7cd
1 changed files with 72 additions and 0 deletions

View File

@ -700,3 +700,75 @@ class BaremetalRedfishIPxeAnacondaNoGlance(
kernel_ref=CONF.baremetal.anaconda_kernel_ref,
ramdisk_ref=CONF.baremetal.anaconda_initial_ramdisk_ref,
stage2_ref=CONF.baremetal.anaconda_stage2_ramdisk_ref)
class BaremetalChangeBaseBootInterface(
bsm.BaremetalStandaloneScenarioTest):
# NOTE(TheJulia): The resource setup class *already* auto-sets the
# requested boot interface. We just never tried to articulate
# this sort of configuration before this class.
# The goal: Test as many boot interfaces to ensure they are functional
# under the base context
api_microversion = '1.31' # to set the boot_interface
driver = None
# This is intentionally meant to be a relatively light weight test,
# but one that covers the common cases, i.e. direct is most appropriate
# here. Ramdisk/anaconda/ansible and friends are all more specific
# cased.
deploy_interface = 'direct'
image_ref = CONF.baremetal.whole_disk_image_url
image_checksum = CONF.baremetal.whole_disk_image_checksum
wholedisk_image = True
class BaremetalPXEBootTestClass(BaremetalChangeBaseBootInterface):
boot_interface = 'pxe'
@decorators.idempotent_id('62c12d2c-8c9f-4526-b9ab-b9cd63e0ea8a')
@utils.services('network')
def test_ip_access_to_server(self):
self.boot_and_verify_node()
class BaremetalIPXEBootTestClass(BaremetalChangeBaseBootInterface):
boot_interface = 'ipxe'
@decorators.idempotent_id('113acd0a-9872-4631-b3ee-54da7e3bb262')
@utils.services('network')
def test_ip_access_to_server(self):
self.boot_and_verify_node()
class BaremetalHTTPBootTestClass(BaremetalChangeBaseBootInterface):
boot_interface = 'http'
@decorators.idempotent_id('782c43db-77a1-4a3a-b46e-0ce9cbb7fba5')
@utils.services('network')
def test_ip_access_to_server(self):
self.boot_and_verify_node()
class BaremetalHttpIPXEBootTestClass(BaremetalChangeBaseBootInterface):
boot_interface = 'http-ipxe'
@decorators.idempotent_id('45400d8e-55a5-4ba6-81f5-935a4183ed90')
@utils.services('network')
def test_ip_access_to_server(self):
self.boot_and_verify_node()
class BaremetalRedfishVmediaBootTestClass(BaremetalChangeBaseBootInterface):
boot_interface = 'redfish-virtual-media'
driver = 'redfish'
@decorators.idempotent_id('10535270-27e5-4616-9013-9507b1960dfa')
@utils.services('network')
def test_ip_access_to_server(self):
self.boot_and_verify_node()