From f0dd9996cc635709276f51e4d94c5ebbf5d5b49f Mon Sep 17 00:00:00 2001 From: ghanshyam Date: Mon, 26 Nov 2018 07:38:54 +0000 Subject: [PATCH] Fix DevStack to configure tempest's service_availability Tempest's service_availability config option includes all the service availability which is further used by tests to take decision of skip or run the test. For example, [service_availability].nova is true then, compute test will run or if [service_availability].aodh is false then, all aodh related tests either in aodh tempest plugin or any other plugins will be skipped. Now question is what is the best way to set the each service availability for tempest or tempest plugins tests. We have 2 category of service here- 1. Service tested by Tempest (nova, cinder, keystone, glance, swift, neutron) (let's say type1 service) 2. Services tested by Tempest plugins (all other than above list) (let's say type2 service) We need the standard way to set both type of service so that we can maintain the setting of service_availability config options in consistent way. As discussed on bug#1743688/ and review https://review.openstack.org/#/c/536723/, we will use devstack lib/tempest to set the type1 service which is services test owned by Tempest and type2 service setting will be done by devstack plugins of those service. For example - [service_availability].ironic will be set by ironic's devstack plugin. because that is best place we know ironic is installed and available. To do that we need: 1. Add setting of [service_availability].* in devstack plugins 2. Remove setting of type2 service from devstack lib/tempest This commit does the second part and all depends-on patches handle the first part. Related-Bug: #1743688 Change-Id: If3aec9fd1c61e2bb53233be437b97b811dc82414 --- lib/tempest | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lib/tempest b/lib/tempest index fba8826a2d..00e946e549 100644 --- a/lib/tempest +++ b/lib/tempest @@ -543,11 +543,15 @@ function configure_tempest { # ``service_available`` # - # this tempest service list needs to be all the services that - # tempest supports, otherwise we can have an erroneous set of + # this tempest service list needs to be the services that + # tempest own, otherwise we can have an erroneous set of # defaults (something defaulting true in Tempest, but not listed here). + # services tested by tempest plugins needs to be set on service devstack + # plugin side as devstack cannot keep track of all the tempest plugins + # services. Refer Bug#1743688 for more details. + # 'horizon' is also kept here as no devtack plugin for horizon. local service - local tempest_services="key,glance,nova,neutron,cinder,swift,heat,ceilometer,horizon,sahara,ironic,trove" + local tempest_services="key,glance,nova,neutron,cinder,swift,horizon" for service in ${tempest_services//,/ }; do if is_service_enabled $service ; then iniset $TEMPEST_CONFIG service_available $service "True"