Invoke allocation tests with 'fake' deploy interface
So it turns out as highlighted by looking at bug 2054722 that you can end up creating nodes with "fake" hardware nodes in the default config we test in the gate, which end up with "fake" as the deploy_interface, but if you try to run the same test against a production configured ironic deployment, it fails because it likely ends up with a default of "agent" as the deploy_interface. Change-Id: Id0051d9b39bc0f46e3afee5bbfa8a2062114df80
This commit is contained in:
parent
621ffd654c
commit
a0b05513f2
@ -39,7 +39,8 @@ class Base(base.BaseBaremetalTest):
|
||||
|
||||
_, self.chassis = self.create_chassis()
|
||||
_, self.node = self.create_node(self.chassis['uuid'],
|
||||
resource_class=self.resource_class)
|
||||
resource_class=self.resource_class,
|
||||
deploy_interface='fake')
|
||||
self.provide_and_power_off_node(self.node['uuid'])
|
||||
|
||||
|
||||
@ -48,6 +49,8 @@ class TestAllocations(Base):
|
||||
|
||||
min_microversion = '1.52'
|
||||
|
||||
deploy_interface = 'fake'
|
||||
|
||||
@decorators.idempotent_id('9203ea28-3c61-4108-8498-22247b654ff6')
|
||||
def test_create_show_allocation(self):
|
||||
self.assertIsNone(self.node['allocation_uuid'])
|
||||
@ -75,7 +78,8 @@ class TestAllocations(Base):
|
||||
@decorators.idempotent_id('eb074d06-e5f4-4fb4-b992-c9929db488ae')
|
||||
def test_create_allocation_with_traits(self):
|
||||
_, node2 = self.create_node(self.chassis['uuid'],
|
||||
resource_class=self.resource_class)
|
||||
resource_class=self.resource_class,
|
||||
deploy_interface='fake')
|
||||
self.client.set_node_traits(node2['uuid'], ['CUSTOM_MEOW'])
|
||||
self.provide_and_power_off_node(node2['uuid'])
|
||||
|
||||
@ -99,7 +103,8 @@ class TestAllocations(Base):
|
||||
node_name = 'allocation-test-1'
|
||||
_, node2 = self.create_node(self.chassis['uuid'],
|
||||
resource_class=self.resource_class,
|
||||
name=node_name)
|
||||
name=node_name,
|
||||
deploy_interface='fake')
|
||||
self.provide_and_power_off_node(node2['uuid'])
|
||||
|
||||
_, body = self.create_allocation(self.resource_class,
|
||||
@ -203,7 +208,8 @@ class TestAllocations(Base):
|
||||
@decorators.idempotent_id('2378727f-77c3-4289-9562-bd2f3b147a60')
|
||||
def test_create_allocation_node_mismatch(self):
|
||||
_, node2 = self.create_node(self.chassis['uuid'],
|
||||
resource_class=self.resource_class + 'alt')
|
||||
resource_class=self.resource_class + 'alt',
|
||||
deploy_interface='fake')
|
||||
# Mismatch between the resource class and the candidate node
|
||||
_, body = self.create_allocation(
|
||||
self.resource_class, candidate_nodes=[node2['uuid']])
|
||||
|
Loading…
Reference in New Issue
Block a user