From 0976ae4ee20c3faf7b2add3893ec3f8cbfa55db1 Mon Sep 17 00:00:00 2001 From: Lucas Alvares Gomes Date: Tue, 1 Sep 2020 10:04:59 +0100 Subject: [PATCH] Skip test_qos_min_bw_allocation_basic when not supported The test_qos_min_bw_allocation_basic relies on a feature [0] which is not supported by all Neutron backends. This test for example will fail for OVN until [0] is implemented for it. This patch makes the test skippable instead of failing when the backend does not support it. [0] https://specs.openstack.org/openstack/neutron-specs/specs/rocky/minimum-bandwidth-allocation-placement-api.html Change-Id: I608c123e69b2e1b34fa0783d03ee5603d901351d Signed-off-by: Lucas Alvares Gomes --- tempest/scenario/test_minbw_allocation_placement.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tempest/scenario/test_minbw_allocation_placement.py b/tempest/scenario/test_minbw_allocation_placement.py index e7085f6a29..5eab1daaeb 100644 --- a/tempest/scenario/test_minbw_allocation_placement.py +++ b/tempest/scenario/test_minbw_allocation_placement.py @@ -124,8 +124,11 @@ class MinBwAllocationPlacementTest(manager.NetworkScenarioTest): resources1='%s:%s' % (self.INGRESS_RESOURCE_CLASS, self.SMALLEST_POSSIBLE_BW)) if len(alloc_candidates['provider_summaries']) == 0: - self.fail('No allocation candidates are available for %s:%s' % - (self.INGRESS_RESOURCE_CLASS, self.SMALLEST_POSSIBLE_BW)) + # Skip if the backend does not support QoS minimum bandwidth + # allocation in Placement API + raise self.skipException( + 'No allocation candidates are available for %s:%s' % + (self.INGRESS_RESOURCE_CLASS, self.SMALLEST_POSSIBLE_BW)) # Just to be sure check with impossible high (placement max_int), # allocation