Convert all service clients to global CONF object
This commit takes the rest client and all subclass(all the service
clients) and converts all uses of config to the global CONF object.
Partially implements bp config-cleanup
Change-Id: I09525af4f1b308b91d45b7bbea05e0f734ea485c
diff --git a/tempest/services/compute/xml/services_client.py b/tempest/services/compute/xml/services_client.py
index 8ef0aa8..bfc824d 100644
--- a/tempest/services/compute/xml/services_client.py
+++ b/tempest/services/compute/xml/services_client.py
@@ -17,18 +17,22 @@
import urllib
from lxml import etree
+
from tempest.common.rest_client import RestClientXML
+from tempest import config
from tempest.services.compute.xml.common import Document
from tempest.services.compute.xml.common import Element
from tempest.services.compute.xml.common import xml_to_json
+CONF = config.CONF
+
class ServicesClientXML(RestClientXML):
- def __init__(self, config, username, password, auth_url, tenant_name=None):
- super(ServicesClientXML, self).__init__(config, username, password,
+ def __init__(self, username, password, auth_url, tenant_name=None):
+ super(ServicesClientXML, self).__init__(username, password,
auth_url, tenant_name)
- self.service = self.config.compute.catalog_type
+ self.service = CONF.compute.catalog_type
def list_services(self, params=None):
url = 'os-services'