Merge "Simplify xml-json inheritance in compute"
diff --git a/tempest/tests/compute/admin/test_flavors.py b/tempest/tests/compute/admin/test_flavors.py
index 30c3d59..7fabf7a 100644
--- a/tempest/tests/compute/admin/test_flavors.py
+++ b/tempest/tests/compute/admin/test_flavors.py
@@ -23,14 +23,17 @@
 from tempest.tests.compute import base
 
 
-class FlavorsAdminTestBase(object):
+class FlavorsAdminTestJSON(base.BaseComputeAdminTest):
 
     """
     Tests Flavors API Create and Delete that require admin privileges
     """
 
+    _interface = 'json'
+
     @classmethod
-    def setUpClass(self, cls):
+    def setUpClass(cls):
+        super(FlavorsAdminTestJSON, cls).setUpClass()
         if not compute.FLAVOR_EXTRA_DATA_ENABLED:
             msg = "FlavorExtraData extension not enabled."
             raise cls.skipException(msg)
@@ -315,23 +318,5 @@
 #TODO(afazekas): Negative tests with regular user
 
 
-class FlavorsAdminTestXML(base.BaseComputeAdminTestXML,
-                          base.BaseComputeTestXML,
-                          FlavorsAdminTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(FlavorsAdminTestXML, cls).setUpClass()
-        base.BaseComputeTestXML.setUpClass()
-        FlavorsAdminTestBase.setUpClass(cls)
-
-
-class FlavorsAdminTestJSON(base.BaseComputeAdminTestJSON,
-                           base.BaseComputeTestJSON,
-                           FlavorsAdminTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(FlavorsAdminTestJSON, cls).setUpClass()
-        base.BaseComputeTestJSON.setUpClass()
-        FlavorsAdminTestBase.setUpClass(cls)
+class FlavorsAdminTestXML(FlavorsAdminTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/admin/test_flavors_extra_specs.py b/tempest/tests/compute/admin/test_flavors_extra_specs.py
index 968603d..711b73f 100644
--- a/tempest/tests/compute/admin/test_flavors_extra_specs.py
+++ b/tempest/tests/compute/admin/test_flavors_extra_specs.py
@@ -21,7 +21,7 @@
 import testtools
 
 
-class FlavorsExtraSpecsTestBase(object):
+class FlavorsExtraSpecsTestJSON(base.BaseComputeAdminTest):
 
     """
     Tests Flavor Extra Spec API extension.
@@ -29,8 +29,11 @@
     GET Flavor Extra specs can be performed even by without admin privileges.
     """
 
+    _interface = 'json'
+
     @classmethod
-    def setUpClass(self, cls):
+    def setUpClass(cls):
+        super(FlavorsExtraSpecsTestJSON, cls).setUpClass()
         if not compute.FLAVOR_EXTRA_DATA_ENABLED:
             msg = "FlavorExtraData extension not enabled."
             raise cls.skipException(msg)
@@ -53,8 +56,9 @@
                                                     swap=swap, rxtx=rxtx)
 
     @classmethod
-    def tearDownClass(self, cls):
+    def tearDownClass(cls):
         resp, body = cls.client.delete_flavor(cls.flavor['id'])
+        super(FlavorsExtraSpecsTestJSON, cls).tearDownClass()
 
     def test_flavor_set_get_unset_keys(self):
         #Test to SET, GET UNSET flavor extra spec as a user
@@ -123,33 +127,5 @@
             self.fail(msg)
 
 
-class FlavorsExtraSpecsTestXML(base.BaseComputeAdminTestXML,
-                               base.BaseComputeTestXML,
-                               FlavorsExtraSpecsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(FlavorsExtraSpecsTestXML, cls).setUpClass()
-        base.BaseComputeTestXML.setUpClass()
-        FlavorsExtraSpecsTestBase.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        FlavorsExtraSpecsTestBase.tearDownClass(cls)
-        super(FlavorsExtraSpecsTestXML, cls).tearDownClass()
-
-
-class FlavorsExtraSpecsTestJSON(base.BaseComputeAdminTestJSON,
-                                base.BaseComputeTestJSON,
-                                FlavorsExtraSpecsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(FlavorsExtraSpecsTestJSON, cls).setUpClass()
-        base.BaseComputeTestJSON.setUpClass()
-        FlavorsExtraSpecsTestBase.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        FlavorsExtraSpecsTestBase.tearDownClass(cls)
-        super(FlavorsExtraSpecsTestJSON, cls).tearDownClass()
+class FlavorsExtraSpecsTestXML(FlavorsExtraSpecsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/admin/test_quotas.py b/tempest/tests/compute/admin/test_quotas.py
index a845632..d63f72f 100644
--- a/tempest/tests/compute/admin/test_quotas.py
+++ b/tempest/tests/compute/admin/test_quotas.py
@@ -20,10 +20,12 @@
 from tempest.tests.compute import base
 
 
-class QuotasAdminTestBase(object):
+class QuotasAdminTestJSON(base.BaseComputeAdminTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
+        super(QuotasAdminTestJSON, cls).setUpClass()
         cls.auth_url = cls.config.identity.uri
         cls.client = cls.os.quotas_client
         cls.adm_client = cls.os_adm.quotas_client
@@ -54,6 +56,7 @@
                 cls.servers_client.delete_server(server['id'])
             except exceptions.NotFound:
                 continue
+        super(QuotasAdminTestJSON, cls).tearDownClass()
 
     @attr(type='smoke')
     def test_get_default_quotas(self):
@@ -150,31 +153,5 @@
 #TODO(afazekas): Add test that tried to update the quota_set as a regular user
 
 
-class QuotasAdminTestJSON(QuotasAdminTestBase, base.BaseComputeAdminTestJSON,
-                          base.BaseComputeTest):
-
-    @classmethod
-    def setUpClass(cls):
-        base.BaseComputeAdminTestJSON.setUpClass()
-        base.BaseComputeTest.setUpClass()
-        super(QuotasAdminTestJSON, cls).setUpClass()
-
-    @classmethod
-    def tearDownClass(cls):
-        super(QuotasAdminTestJSON, cls).tearDownClass()
-        base.BaseComputeTest.tearDownClass()
-
-
-class QuotasAdminTestXML(QuotasAdminTestBase, base.BaseComputeAdminTestXML,
-                         base.BaseComputeTest):
-
-    @classmethod
-    def setUpClass(cls):
-        base.BaseComputeAdminTestXML.setUpClass()
-        base.BaseComputeTest.setUpClass()
-        super(QuotasAdminTestXML, cls).setUpClass()
-
-    @classmethod
-    def tearDownClass(cls):
-        super(QuotasAdminTestXML, cls).tearDownClass()
-        base.BaseComputeTest.tearDownClass()
+class QuotasAdminTestXML(QuotasAdminTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/base.py b/tempest/tests/compute/base.py
index 2c6b861..b1ed5b5 100644
--- a/tempest/tests/compute/base.py
+++ b/tempest/tests/compute/base.py
@@ -27,15 +27,13 @@
 from tempest import exceptions
 from tempest.tests import compute
 
-__all__ = ['BaseComputeTest', 'BaseComputeTestJSON', 'BaseComputeTestXML',
-           'BaseComputeAdminTestJSON', 'BaseComputeAdminTestXML']
 
 LOG = logging.getLogger(__name__)
 
 
-class BaseCompTest(testtools.testcase.WithAttributes,
-                   testtools.TestCase,
-                   testresources.ResourcedTestCase):
+class BaseComputeTest(testtools.testcase.WithAttributes,
+                      testtools.TestCase,
+                      testresources.ResourcedTestCase):
     """Base test case class for all Compute API tests."""
 
     conclusion = compute.generic_setup_package()
@@ -230,24 +228,7 @@
             time.sleep(self.build_interval)
 
 
-class BaseComputeTestJSON(BaseCompTest):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "json"
-        super(BaseComputeTestJSON, cls).setUpClass()
-
-# NOTE(danms): For transition, keep the old name active as JSON
-BaseComputeTest = BaseComputeTestJSON
-
-
-class BaseComputeTestXML(BaseCompTest):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "xml"
-        super(BaseComputeTestXML, cls).setUpClass()
-
-
-class BaseComputeAdminTest(BaseCompTest):
+class BaseComputeAdminTest(BaseComputeTest):
 
     """Base test case class for all Compute Admin API tests."""
 
@@ -264,17 +245,3 @@
             raise cls.skipException(msg)
 
         cls.os_adm = clients.ComputeAdminManager(interface=cls._interface)
-
-
-class BaseComputeAdminTestJSON(BaseComputeAdminTest):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "json"
-        super(BaseComputeAdminTestJSON, cls).setUpClass()
-
-
-class BaseComputeAdminTestXML(BaseComputeAdminTest):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "xml"
-        super(BaseComputeAdminTestXML, cls).setUpClass()
diff --git a/tempest/tests/compute/flavors/test_flavors.py b/tempest/tests/compute/flavors/test_flavors.py
index 8b49390..95244df 100644
--- a/tempest/tests/compute/flavors/test_flavors.py
+++ b/tempest/tests/compute/flavors/test_flavors.py
@@ -20,7 +20,13 @@
 from tempest.tests.compute import base
 
 
-class FlavorsTestBase(object):
+class FlavorsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(FlavorsTestJSON, cls).setUpClass()
+        cls.client = cls.flavors_client
 
     @attr(type='smoke')
     def test_list_flavors(self):
@@ -149,19 +155,5 @@
                           9999)
 
 
-class FlavorsTestXML(base.BaseComputeTestXML,
-                     FlavorsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(FlavorsTestXML, cls).setUpClass()
-        cls.client = cls.flavors_client
-
-
-class FlavorsTestJSON(base.BaseComputeTestJSON,
-                      FlavorsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(FlavorsTestJSON, cls).setUpClass()
-        cls.client = cls.flavors_client
+class FlavorsTestXML(FlavorsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/floating_ips/test_floating_ips_actions.py b/tempest/tests/compute/floating_ips/test_floating_ips_actions.py
index 165cf79..ffff1f7 100644
--- a/tempest/tests/compute/floating_ips/test_floating_ips_actions.py
+++ b/tempest/tests/compute/floating_ips/test_floating_ips_actions.py
@@ -21,12 +21,14 @@
 from tempest.tests.compute import base
 
 
-class FloatingIPsTestBase(object):
+class FloatingIPsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
     server_id = None
     floating_ip = None
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(FloatingIPsTestJSON, cls).setUpClass()
         cls.client = cls.floating_ips_client
         cls.servers_client = cls.servers_client
 
@@ -51,8 +53,9 @@
             if cls.non_exist_id not in cls.floating_ip_ids:
                 break
 
-    @staticmethod
+    @classmethod
     def tearDownClass(cls):
+        super(FloatingIPsTestJSON, cls).tearDownClass()
         #Deleting the server which is created in this method
         resp, body = cls.servers_client.delete_server(cls.server_id)
         #Deleting the floating IP which is created in this method
@@ -202,25 +205,5 @@
                       ' with out passing floating IP  should raise BadRequest')
 
 
-class FloatingIPsTestJSON(base.BaseComputeTestJSON, FloatingIPsTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(FloatingIPsTestJSON, cls).setUpClass()
-        FloatingIPsTestBase.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        FloatingIPsTestBase.tearDownClass(cls)
-        super(FloatingIPsTestJSON, cls).tearDownClass()
-
-
-class FloatingIPsTestXML(base.BaseComputeTestXML, FloatingIPsTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(FloatingIPsTestXML, cls).setUpClass()
-        FloatingIPsTestBase.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        FloatingIPsTestBase.tearDownClass(cls)
-        super(FloatingIPsTestXML, cls).tearDownClass()
+class FloatingIPsTestXML(FloatingIPsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/floating_ips/test_list_floating_ips.py b/tempest/tests/compute/floating_ips/test_list_floating_ips.py
index 42befd0..11b9465 100644
--- a/tempest/tests/compute/floating_ips/test_list_floating_ips.py
+++ b/tempest/tests/compute/floating_ips/test_list_floating_ips.py
@@ -21,10 +21,12 @@
 from tempest.tests.compute import base
 
 
-class FloatingIPDetailsTestBase(object):
+class FloatingIPDetailsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(FloatingIPDetailsTestJSON, cls).setUpClass()
         cls.client = cls.floating_ips_client
         cls.floating_ip = []
         cls.floating_ip_id = []
@@ -34,10 +36,11 @@
             cls.floating_ip.append(body)
             cls.floating_ip_id.append(body['id'])
 
-    @staticmethod
+    @classmethod
     def tearDownClass(cls):
         for i in range(3):
             cls.client.delete_floating_ip(cls.floating_ip_id[i])
+        super(FloatingIPDetailsTestJSON, cls).tearDownClass()
 
     @attr(type='positive')
     def test_list_floating_ips(self):
@@ -97,27 +100,5 @@
                       'nonexistant floating IP')
 
 
-class FloatingIPDetailsTestJSON(base.BaseComputeTestJSON,
-                                FloatingIPDetailsTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(FloatingIPDetailsTestJSON, cls).setUpClass()
-        FloatingIPDetailsTestBase.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        FloatingIPDetailsTestBase.tearDownClass(cls)
-        super(FloatingIPDetailsTestJSON, cls).tearDownClass()
-
-
-class FloatingIPDetailsTestXML(base.BaseComputeTestXML,
-                               FloatingIPDetailsTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(FloatingIPDetailsTestXML, cls).setUpClass()
-        FloatingIPDetailsTestBase.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        FloatingIPDetailsTestBase.tearDownClass(cls)
-        super(FloatingIPDetailsTestXML, cls).tearDownClass()
+class FloatingIPDetailsTestXML(FloatingIPDetailsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/images/test_image_metadata.py b/tempest/tests/compute/images/test_image_metadata.py
index 7119a8e..fa69395 100644
--- a/tempest/tests/compute/images/test_image_metadata.py
+++ b/tempest/tests/compute/images/test_image_metadata.py
@@ -18,10 +18,11 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest import exceptions
 from tempest.test import attr
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class ImagesMetadataTest(BaseComputeTest):
+class ImagesMetadataTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/images/test_images.py b/tempest/tests/compute/images/test_images.py
index edc58e7..d8d38aa 100644
--- a/tempest/tests/compute/images/test_images.py
+++ b/tempest/tests/compute/images/test_images.py
@@ -26,7 +26,28 @@
 from tempest.tests.compute import base
 
 
-class ImagesTestBase(object):
+class ImagesTestJSON(base.BaseComputeTest):
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(ImagesTestJSON, cls).setUpClass()
+        cls.client = cls.images_client
+        cls.servers_client = cls.servers_client
+
+        cls.image_ids = []
+
+        if compute.MULTI_USER:
+            if cls.config.compute.allow_tenant_isolation:
+                creds = cls._get_isolated_creds()
+                username, tenant_name, password = creds
+                cls.alt_manager = clients.Manager(username=username,
+                                                  password=password,
+                                                  tenant_name=tenant_name)
+            else:
+                # Use the alt_XXX credentials in the config file
+                cls.alt_manager = clients.AltManager()
+            cls.alt_client = cls.alt_manager.images_client
 
     def tearDown(self):
         """Terminate test instances created after a test is executed."""
@@ -39,6 +60,7 @@
         for image_id in self.image_ids:
             self.client.delete_image(image_id)
             self.image_ids.remove(image_id)
+        super(ImagesTestJSON, self).tearDown()
 
     @attr(type='negative')
     def test_create_image_from_deleted_server(self):
@@ -211,55 +233,5 @@
                       "exceeds 35 character ID length limit")
 
 
-class ImagesTestJSON(base.BaseComputeTestJSON,
-                     ImagesTestBase):
-    def tearDown(self):
-        ImagesTestBase.tearDown(self)
-        base.BaseComputeTestJSON.tearDown(self)
-
-    @classmethod
-    def setUpClass(cls):
-        super(ImagesTestJSON, cls).setUpClass()
-        cls.client = cls.images_client
-        cls.servers_client = cls.servers_client
-
-        cls.image_ids = []
-
-        if compute.MULTI_USER:
-            if cls.config.compute.allow_tenant_isolation:
-                creds = cls._get_isolated_creds()
-                username, tenant_name, password = creds
-                cls.alt_manager = clients.Manager(username=username,
-                                                  password=password,
-                                                  tenant_name=tenant_name)
-            else:
-                # Use the alt_XXX credentials in the config file
-                cls.alt_manager = clients.AltManager()
-            cls.alt_client = cls.alt_manager.images_client
-
-
-class ImagesTestXML(base.BaseComputeTestXML,
-                    ImagesTestBase):
-    def tearDown(self):
-        ImagesTestBase.tearDown(self)
-        base.BaseComputeTestXML.tearDown(self)
-
-    @classmethod
-    def setUpClass(cls):
-        super(ImagesTestXML, cls).setUpClass()
-        cls.client = cls.images_client
-        cls.servers_client = cls.servers_client
-
-        cls.image_ids = []
-
-        if compute.MULTI_USER:
-            if cls.config.compute.allow_tenant_isolation:
-                creds = cls._get_isolated_creds()
-                username, tenant_name, password = creds
-                cls.alt_manager = clients.Manager(username=username,
-                                                  password=password,
-                                                  tenant_name=tenant_name)
-            else:
-                # Use the alt_XXX credentials in the config file
-                cls.alt_manager = clients.AltManager()
-            cls.alt_client = cls.alt_manager.images_client
+class ImagesTestXML(ImagesTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/images/test_images_oneserver.py b/tempest/tests/compute/images/test_images_oneserver.py
index 08966fd..34ea868 100644
--- a/tempest/tests/compute/images/test_images_oneserver.py
+++ b/tempest/tests/compute/images/test_images_oneserver.py
@@ -26,12 +26,36 @@
 from tempest.tests.compute import base
 
 
-class ImagesOneServerTestBase(object):
+class ImagesOneServerTestJSON(base.BaseComputeTest):
+    _interface = 'json'
+
     def tearDown(self):
         """Terminate test instances created after a test is executed."""
         for image_id in self.image_ids:
             self.client.delete_image(image_id)
             self.image_ids.remove(image_id)
+        super(ImagesOneServerTestJSON, self).tearDown()
+
+    @classmethod
+    def setUpClass(cls):
+        super(ImagesOneServerTestJSON, cls).setUpClass()
+        cls.client = cls.images_client
+        cls.servers_client = cls.servers_client
+        cls.server = cls.create_server()
+
+        cls.image_ids = []
+
+        if compute.MULTI_USER:
+            if cls.config.compute.allow_tenant_isolation:
+                creds = cls._get_isolated_creds()
+                username, tenant_name, password = creds
+                cls.alt_manager = clients.Manager(username=username,
+                                                  password=password,
+                                                  tenant_name=tenant_name)
+            else:
+                # Use the alt_XXX credentials in the config file
+                cls.alt_manager = clients.AltManager()
+            cls.alt_client = cls.alt_manager.images_client
 
     @attr(type='negative')
     @testtools.skip("Until Bug 1006725 is fixed")
@@ -178,59 +202,5 @@
         self.assertRaises(exceptions.NotFound, self.client.get_image, image_id)
 
 
-class ImagesOneServerTestJSON(base.BaseComputeTestJSON,
-                              ImagesOneServerTestBase):
-
-    def tearDown(self):
-        ImagesOneServerTestBase.tearDown(self)
-        base.BaseComputeTestJSON.tearDown(self)
-
-    @classmethod
-    def setUpClass(cls):
-        super(ImagesOneServerTestJSON, cls).setUpClass()
-        cls.client = cls.images_client
-        cls.servers_client = cls.servers_client
-        cls.server = cls.create_server()
-
-        cls.image_ids = []
-
-        if compute.MULTI_USER:
-            if cls.config.compute.allow_tenant_isolation:
-                creds = cls._get_isolated_creds()
-                username, tenant_name, password = creds
-                cls.alt_manager = clients.Manager(username=username,
-                                                  password=password,
-                                                  tenant_name=tenant_name)
-            else:
-                # Use the alt_XXX credentials in the config file
-                cls.alt_manager = clients.AltManager()
-            cls.alt_client = cls.alt_manager.images_client
-
-
-class ImagesOneServerTestXML(base.BaseComputeTestXML,
-                             ImagesOneServerTestBase):
-
-    def tearDown(self):
-        ImagesOneServerTestBase.tearDown(self)
-        base.BaseComputeTestXML.tearDown(self)
-
-    @classmethod
-    def setUpClass(cls):
-        super(ImagesOneServerTestXML, cls).setUpClass()
-        cls.client = cls.images_client
-        cls.servers_client = cls.servers_client
-        cls.server = cls.create_server()
-
-        cls.image_ids = []
-
-        if compute.MULTI_USER:
-            if cls.config.compute.allow_tenant_isolation:
-                creds = cls._get_isolated_creds()
-                username, tenant_name, password = creds
-                cls.alt_manager = clients.Manager(username=username,
-                                                  password=password,
-                                                  tenant_name=tenant_name)
-            else:
-                # Use the alt_XXX credentials in the config file
-                cls.alt_manager = clients.AltManager()
-            cls.alt_client = cls.alt_manager.images_client
+class ImagesOneServerTestXML(ImagesOneServerTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/images/test_images_whitebox.py b/tempest/tests/compute/images/test_images_whitebox.py
index 88f3b53..8af812c 100644
--- a/tempest/tests/compute/images/test_images_whitebox.py
+++ b/tempest/tests/compute/images/test_images_whitebox.py
@@ -24,6 +24,7 @@
 
 @attr(type='whitebox')
 class ImagesWhiteboxTest(whitebox.ComputeWhiteboxTest, base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/images/test_list_image_filters.py b/tempest/tests/compute/images/test_list_image_filters.py
index 316d90a..56f388d 100644
--- a/tempest/tests/compute/images/test_list_image_filters.py
+++ b/tempest/tests/compute/images/test_list_image_filters.py
@@ -19,10 +19,11 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest import exceptions
 from tempest.test import attr
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class ListImageFiltersTest(BaseComputeTest):
+class ListImageFiltersTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/images/test_list_images.py b/tempest/tests/compute/images/test_list_images.py
index 0f661b7..d583a95 100644
--- a/tempest/tests/compute/images/test_list_images.py
+++ b/tempest/tests/compute/images/test_list_images.py
@@ -16,10 +16,11 @@
 #    under the License.
 
 from tempest.test import attr
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class ListImagesTest(BaseComputeTest):
+class ListImagesTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/keypairs/test_keypairs.py b/tempest/tests/compute/keypairs/test_keypairs.py
index 6f4569b..aefc5ff 100644
--- a/tempest/tests/compute/keypairs/test_keypairs.py
+++ b/tempest/tests/compute/keypairs/test_keypairs.py
@@ -20,11 +20,16 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest import exceptions
 from tempest.test import attr
-from tempest.tests.compute.base import BaseComputeTestJSON
-from tempest.tests.compute.base import BaseComputeTestXML
+from tempest.tests.compute import base
 
 
-class KeyPairsTestBase(object):
+class KeyPairsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(KeyPairsTestJSON, cls).setUpClass()
+        cls.client = cls.keypairs_client
 
     @attr(type='positive')
     def test_keypairs_create_list_delete(self):
@@ -222,15 +227,5 @@
             self.fail('invalid name')
 
 
-class KeyPairsTestXML(BaseComputeTestXML, KeyPairsTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(KeyPairsTestXML, cls).setUpClass()
-        cls.client = cls.keypairs_client
-
-
-class KeyPairsTestJSON(BaseComputeTestJSON, KeyPairsTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(KeyPairsTestJSON, cls).setUpClass()
-        cls.client = cls.keypairs_client
+class KeyPairsTestXML(KeyPairsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/limits/test_absolute_limits.py b/tempest/tests/compute/limits/test_absolute_limits.py
index 4b17af9..129339c 100644
--- a/tempest/tests/compute/limits/test_absolute_limits.py
+++ b/tempest/tests/compute/limits/test_absolute_limits.py
@@ -20,10 +20,12 @@
 from tempest.tests.compute import base
 
 
-class AbsoluteLimitsTest(object):
+class AbsoluteLimitsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(AbsoluteLimitsTestJSON, cls).setUpClass()
         cls.client = cls.limits_client
 
     def test_absLimits_get(self):
@@ -46,17 +48,5 @@
                          % ', '.join(ele for ele in missing_elements))
 
 
-class AbsoluteLimitsTestJSON(base.BaseComputeTestJSON,
-                             AbsoluteLimitsTest):
-    @classmethod
-    def setUpClass(cls):
-        super(AbsoluteLimitsTestJSON, cls).setUpClass()
-        AbsoluteLimitsTest.setUpClass(cls)
-
-
-class AbsoluteLimitsTestXML(base.BaseComputeTestXML,
-                            AbsoluteLimitsTest):
-    @classmethod
-    def setUpClass(cls):
-        super(AbsoluteLimitsTestXML, cls).setUpClass()
-        AbsoluteLimitsTest.setUpClass(cls)
+class AbsoluteLimitsTestXML(AbsoluteLimitsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/security_groups/test_security_group_rules.py b/tempest/tests/compute/security_groups/test_security_group_rules.py
index 41ad2c8..5063fd3 100644
--- a/tempest/tests/compute/security_groups/test_security_group_rules.py
+++ b/tempest/tests/compute/security_groups/test_security_group_rules.py
@@ -21,10 +21,12 @@
 from tempest.tests.compute import base
 
 
-class SecurityGroupRulesTest(object):
+class SecurityGroupRulesTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(SecurityGroupRulesTestJSON, cls).setUpClass()
         cls.client = cls.security_groups_client
 
     @attr(type='positive')
@@ -243,17 +245,5 @@
                       'with nonexistant rule id')
 
 
-class SecurityGroupRulesTestJSON(base.BaseComputeTestJSON,
-                                 SecurityGroupRulesTest):
-    @classmethod
-    def setUpClass(cls):
-        super(SecurityGroupRulesTestJSON, cls).setUpClass()
-        SecurityGroupRulesTest.setUpClass(cls)
-
-
-class SecurityGroupRulesTestXML(base.BaseComputeTestXML,
-                                SecurityGroupRulesTest):
-    @classmethod
-    def setUpClass(cls):
-        super(SecurityGroupRulesTestXML, cls).setUpClass()
-        SecurityGroupRulesTest.setUpClass(cls)
+class SecurityGroupRulesTestXML(SecurityGroupRulesTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/security_groups/test_security_groups.py b/tempest/tests/compute/security_groups/test_security_groups.py
index f6caf2b..c086280 100644
--- a/tempest/tests/compute/security_groups/test_security_groups.py
+++ b/tempest/tests/compute/security_groups/test_security_groups.py
@@ -21,10 +21,12 @@
 from tempest.tests.compute import base
 
 
-class SecurityGroupsTest(object):
+class SecurityGroupsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(SecurityGroupsTestJSON, cls).setUpClass()
         cls.client = cls.security_groups_client
 
     @attr(type='positive')
@@ -297,17 +299,5 @@
         self.assertEqual(202, resp.status)
 
 
-class SecurityGroupsTestJSON(base.BaseComputeTestJSON,
-                             SecurityGroupsTest):
-    @classmethod
-    def setUpClass(cls):
-        super(SecurityGroupsTestJSON, cls).setUpClass()
-        SecurityGroupsTest.setUpClass(cls)
-
-
-class SecurityGroupsTestXML(base.BaseComputeTestXML,
-                            SecurityGroupsTest):
-    @classmethod
-    def setUpClass(cls):
-        super(SecurityGroupsTestXML, cls).setUpClass()
-        SecurityGroupsTest.setUpClass(cls)
+class SecurityGroupsTestXML(SecurityGroupsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/servers/test_console_output.py b/tempest/tests/compute/servers/test_console_output.py
index bdf449d..4ddbc2f 100644
--- a/tempest/tests/compute/servers/test_console_output.py
+++ b/tempest/tests/compute/servers/test_console_output.py
@@ -23,10 +23,14 @@
 from tempest.tests.compute import base
 
 
-class ConsoleOutputTest(object):
+#TODO(afazekas): move these to the server actions test
+@attr(type='smoke')
+class ConsoleOutputTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
-    def setUpClass(self, cls):
+    def setUpClass(cls):
+        super(ConsoleOutputTestJSON, cls).setUpClass()
         cls.name = rand_name('server')
         resp, server = cls.servers_client.create_server(cls.name,
                                                         cls.image_ref,
@@ -36,8 +40,9 @@
         cls.servers_client.wait_for_server_status(cls.server_id, 'ACTIVE')
 
     @classmethod
-    def tearDownClass(self, cls):
+    def tearDownClass(cls):
         cls.servers_client.delete_server(cls.server_id)
+        super(ConsoleOutputTestJSON, cls).tearDownClass()
 
     @attr(type='positive')
     def test_get_console_output(self):
@@ -87,28 +92,5 @@
 
 
 @attr(type='smoke')
-class ConsoleOutputTestJSON(base.BaseComputeTestJSON,
-                            ConsoleOutputTest):
-    @classmethod
-    def setUpClass(cls):
-        super(ConsoleOutputTestJSON, cls).setUpClass()
-        ConsoleOutputTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        ConsoleOutputTest.tearDownClass(cls)
-        super(ConsoleOutputTestJSON, cls).tearDownClass()
-
-
-@attr(type='smoke')
-class ConsoleOutputTestXML(base.BaseComputeTestXML,
-                           ConsoleOutputTest):
-    @classmethod
-    def setUpClass(cls):
-        super(ConsoleOutputTestXML, cls).setUpClass()
-        ConsoleOutputTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        ConsoleOutputTest.tearDownClass(cls)
-        super(ConsoleOutputTestXML, cls).tearDownClass()
+class ConsoleOutputTestXML(ConsoleOutputTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/servers/test_create_server.py b/tempest/tests/compute/servers/test_create_server.py
index 838b382..3c8aeda 100644
--- a/tempest/tests/compute/servers/test_create_server.py
+++ b/tempest/tests/compute/servers/test_create_server.py
@@ -29,12 +29,15 @@
 from tempest.tests.compute import base
 
 
-class ServersTest(object):
-
+@attr(type='smoke')
+class ServersTestJSON(base.BaseComputeTest):
+    _interface = 'json'
     run_ssh = tempest.config.TempestConfig().compute.run_ssh
+    disk_config = None
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(ServersTestJSON, cls).setUpClass()
         cls.meta = {'hello': 'world'}
         cls.accessIPv4 = '1.1.1.1'
         cls.accessIPv6 = '0000:0000:0000:0000:0000:babe:220.12.22.2'
@@ -56,9 +59,10 @@
         cls.client.wait_for_server_status(cls.server_initial['id'], 'ACTIVE')
         resp, cls.server = cls.client.get_server(cls.server_initial['id'])
 
-    @staticmethod
+    @classmethod
     def tearDownClass(cls):
         cls.client.delete_server(cls.server_initial['id'])
+        super(ServersTestJSON, cls).tearDownClass()
 
     @attr(type='smoke')
     def test_create_server_response(self):
@@ -121,66 +125,28 @@
 
 
 @attr(type='positive')
-class ServersTestAutoDisk(base.BaseComputeTestJSON,
-                          ServersTest):
+class ServersTestAutoDisk(ServersTestJSON):
+    disk_config = 'AUTO'
+
     @classmethod
     def setUpClass(cls):
         if not compute.DISK_CONFIG_ENABLED:
             msg = "DiskConfig extension not enabled."
             raise cls.skipException(msg)
         super(ServersTestAutoDisk, cls).setUpClass()
-        cls.disk_config = 'AUTO'
-        ServersTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        ServersTest.tearDownClass(cls)
-        super(ServersTestAutoDisk, cls).tearDownClass()
 
 
 @attr(type='positive')
-class ServersTestManualDisk(base.BaseComputeTestJSON,
-                            ServersTest):
+class ServersTestManualDisk(ServersTestJSON):
+    disk_config = 'MANUAL'
+
     @classmethod
     def setUpClass(cls):
         if not compute.DISK_CONFIG_ENABLED:
             msg = "DiskConfig extension not enabled."
             raise cls.skipException(msg)
         super(ServersTestManualDisk, cls).setUpClass()
-        cls.disk_config = 'MANUAL'
-        ServersTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        ServersTest.tearDownClass(cls)
-        super(ServersTestManualDisk, cls).tearDownClass()
 
 
-@attr(type='smoke')
-class ServersTestJSON(base.BaseComputeTestJSON,
-                      ServersTest):
-    @classmethod
-    def setUpClass(cls):
-        super(ServersTestJSON, cls).setUpClass()
-        cls.disk_config = None
-        ServersTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        ServersTest.tearDownClass(cls)
-        super(ServersTestJSON, cls).tearDownClass()
-
-
-@attr(type='smoke')
-class ServersTestXML(base.BaseComputeTestXML,
-                     ServersTest):
-    @classmethod
-    def setUpClass(cls):
-        super(ServersTestXML, cls).setUpClass()
-        cls.disk_config = None
-        ServersTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        ServersTest.tearDownClass(cls)
-        super(ServersTestXML, cls).tearDownClass()
+class ServersTestXML(ServersTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/servers/test_disk_config.py b/tempest/tests/compute/servers/test_disk_config.py
index 57b95f2..671abf9 100644
--- a/tempest/tests/compute/servers/test_disk_config.py
+++ b/tempest/tests/compute/servers/test_disk_config.py
@@ -20,10 +20,11 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest.test import attr
 from tempest.tests import compute
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class TestServerDiskConfig(BaseComputeTest):
+class TestServerDiskConfig(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/servers/test_list_server_filters.py b/tempest/tests/compute/servers/test_list_server_filters.py
index 9b061b5..897ca34 100644
--- a/tempest/tests/compute/servers/test_list_server_filters.py
+++ b/tempest/tests/compute/servers/test_list_server_filters.py
@@ -23,10 +23,12 @@
 from tempest.tests import utils
 
 
-class ListServerFiltersTest(object):
+class ListServerFiltersTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(ListServerFiltersTestJSON, cls).setUpClass()
         cls.client = cls.servers_client
 
         # Check to see if the alternate image ref actually exists...
@@ -77,11 +79,12 @@
         cls.s2_min = cls._convert_to_min_details(cls.s2)
         cls.s3_min = cls._convert_to_min_details(cls.s3)
 
-    @staticmethod
+    @classmethod
     def tearDownClass(cls):
         cls.client.delete_server(cls.s1['id'])
         cls.client.delete_server(cls.s2['id'])
         cls.client.delete_server(cls.s3['id'])
+        super(ListServerFiltersTestJSON, cls).tearDownClass()
 
     def _server_id_in_results(self, server_id, results):
         ids = [row['id'] for row in results]
@@ -200,27 +203,5 @@
         return min_detail
 
 
-class ListServerFiltersTestJSON(base.BaseComputeTestJSON,
-                                ListServerFiltersTest):
-    @classmethod
-    def setUpClass(cls):
-        super(ListServerFiltersTestJSON, cls).setUpClass()
-        ListServerFiltersTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        super(ListServerFiltersTestJSON, cls).tearDownClass()
-        ListServerFiltersTest.tearDownClass(cls)
-
-
-class ListServerFiltersTestXML(base.BaseComputeTestXML,
-                               ListServerFiltersTest):
-    @classmethod
-    def setUpClass(cls):
-        super(ListServerFiltersTestXML, cls).setUpClass()
-        ListServerFiltersTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        super(ListServerFiltersTestXML, cls).tearDownClass()
-        ListServerFiltersTest.tearDownClass(cls)
+class ListServerFiltersTestXML(ListServerFiltersTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/servers/test_list_servers_negative.py b/tempest/tests/compute/servers/test_list_servers_negative.py
index f93bebf..320f920 100644
--- a/tempest/tests/compute/servers/test_list_servers_negative.py
+++ b/tempest/tests/compute/servers/test_list_servers_negative.py
@@ -19,10 +19,11 @@
 from tempest import clients
 from tempest import exceptions
 from tempest.tests import compute
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class ListServersNegativeTest(BaseComputeTest):
+class ListServersNegativeTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/servers/test_server_actions.py b/tempest/tests/compute/servers/test_server_actions.py
index 06e441a..a9ada39 100644
--- a/tempest/tests/compute/servers/test_server_actions.py
+++ b/tempest/tests/compute/servers/test_server_actions.py
@@ -29,11 +29,26 @@
 from tempest.tests.compute import base
 
 
-class ServerActionsTestBase(object):
-
+class ServerActionsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
     resize_available = tempest.config.TempestConfig().compute.resize_available
     run_ssh = tempest.config.TempestConfig().compute.run_ssh
 
+    def setUp(self):
+        super(ServerActionsTestJSON, self).setUp()
+        # Check if the server is in a clean state after test
+        try:
+            self.client.wait_for_server_status(self.server_id, 'ACTIVE')
+        except exceptions:
+            # Rebuild server if something happened to it during a test
+            self.rebuild_servers()
+
+    @classmethod
+    def setUpClass(cls):
+        super(ServerActionsTestJSON, cls).setUpClass()
+        cls.client = cls.servers_client
+        cls.rebuild_servers()
+
     @attr(type='smoke')
     @testtools.skipUnless(compute.CHANGE_PASSWORD_AVAILABLE,
                           'Change password not available.')
@@ -219,37 +234,5 @@
         cls.client.wait_for_server_status(cls.server_id, 'ACTIVE')
 
 
-class ServerActionsTestXML(base.BaseComputeTestXML,
-                           ServerActionsTestBase):
-    def setUp(self):
-        super(ServerActionsTestXML, self).setUp()
-        # Check if the server is in a clean state after test
-        try:
-            self.client.wait_for_server_status(self.server_id, 'ACTIVE')
-        except exceptions:
-            # Rebuild server if something happened to it during a test
-            self.rebuild_servers()
-
-    @classmethod
-    def setUpClass(cls):
-        super(ServerActionsTestXML, cls).setUpClass()
-        cls.client = cls.servers_client
-        cls.rebuild_servers()
-
-
-class ServerActionsTestJSON(base.BaseComputeTestJSON,
-                            ServerActionsTestBase):
-    def setUp(self):
-        super(ServerActionsTestJSON, self).setUp()
-        # Check if the server is in a clean state after test
-        try:
-            self.client.wait_for_server_status(self.server_id, 'ACTIVE')
-        except exceptions:
-            # Rebuild server if something happened to it during a test
-            self.rebuild_servers()
-
-    @classmethod
-    def setUpClass(cls):
-        super(ServerActionsTestJSON, cls).setUpClass()
-        cls.client = cls.servers_client
-        cls.rebuild_servers()
+class ServerActionsTestXML(ServerActionsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/servers/test_server_addresses.py b/tempest/tests/compute/servers/test_server_addresses.py
index 8888281..b811d52 100644
--- a/tempest/tests/compute/servers/test_server_addresses.py
+++ b/tempest/tests/compute/servers/test_server_addresses.py
@@ -18,10 +18,11 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest import exceptions
 from tempest.test import attr
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class ServerAddressesTest(BaseComputeTest):
+class ServerAddressesTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/servers/test_server_metadata.py b/tempest/tests/compute/servers/test_server_metadata.py
index ce7a6a8..6958a7d 100644
--- a/tempest/tests/compute/servers/test_server_metadata.py
+++ b/tempest/tests/compute/servers/test_server_metadata.py
@@ -18,10 +18,11 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest import exceptions
 from tempest.test import attr
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class ServerMetadataTest(BaseComputeTest):
+class ServerMetadataTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
diff --git a/tempest/tests/compute/servers/test_server_personality.py b/tempest/tests/compute/servers/test_server_personality.py
index 862cfb2..816ca76 100644
--- a/tempest/tests/compute/servers/test_server_personality.py
+++ b/tempest/tests/compute/servers/test_server_personality.py
@@ -23,7 +23,14 @@
 from tempest.tests.compute import base
 
 
-class ServerPersonalityTestBase(object):
+class ServerPersonalityTestJSON(base.BaseComputeTest):
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(ServerPersonalityTestJSON, cls).setUpClass()
+        cls.client = cls.servers_client
+        cls.user_client = cls.limits_client
 
     def test_personality_files_exceed_limit(self):
         # Server creation should fail if greater than the maximum allowed
@@ -74,21 +81,5 @@
             self.client.delete_server(server['id'])
 
 
-class ServerPersonalityTestXML(base.BaseComputeTestXML,
-                               ServerPersonalityTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "xml"
-        super(ServerPersonalityTestXML, cls).setUpClass()
-        cls.client = cls.servers_client
-        cls.user_client = cls.limits_client
-
-
-class ServerPersonalityTestJSON(base.BaseComputeTestJSON,
-                                ServerPersonalityTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "json"
-        super(ServerPersonalityTestJSON, cls).setUpClass()
-        cls.client = cls.servers_client
-        cls.user_client = cls.limits_client
+class ServerPersonalityTestXML(ServerPersonalityTestJSON):
+    _interface = "xml"
diff --git a/tempest/tests/compute/servers/test_servers.py b/tempest/tests/compute/servers/test_servers.py
index caf0679..a912652 100644
--- a/tempest/tests/compute/servers/test_servers.py
+++ b/tempest/tests/compute/servers/test_servers.py
@@ -20,7 +20,13 @@
 from tempest.tests.compute import base
 
 
-class ServersTestBase(object):
+class ServersTestJSON(base.BaseComputeTest):
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(ServersTestJSON, cls).setUpClass()
+        cls.client = cls.servers_client
 
     @attr(type='positive')
     def test_create_server_with_admin_password(self):
@@ -155,15 +161,5 @@
         self.assertEqual('204', resp['status'])
 
 
-class ServersTestJSON(base.BaseComputeTestJSON, ServersTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(ServersTestJSON, cls).setUpClass()
-        cls.client = cls.servers_client
-
-
-class ServersTestXML(base.BaseComputeTestXML, ServersTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(ServersTestXML, cls).setUpClass()
-        cls.client = cls.servers_client
+class ServersTestXML(ServersTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/servers/test_servers_whitebox.py b/tempest/tests/compute/servers/test_servers_whitebox.py
index 94502c3..9b75cd5 100644
--- a/tempest/tests/compute/servers/test_servers_whitebox.py
+++ b/tempest/tests/compute/servers/test_servers_whitebox.py
@@ -23,11 +23,13 @@
 
 @attr(type='whitebox')
 class ServersWhiteboxTest(whitebox.ComputeWhiteboxTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
         raise cls.skipException("Until Bug 1034129 is fixed")
         super(ServersWhiteboxTest, cls).setUpClass()
+        #NOTE(afazekas): Strange relationship
         BaseIdentityAdminTest.setUpClass()
         cls.client = cls.servers_client
         cls.img_client = cls.images_client
diff --git a/tempest/tests/compute/servers/test_virtual_interfaces.py b/tempest/tests/compute/servers/test_virtual_interfaces.py
index 6198526..65da24f 100644
--- a/tempest/tests/compute/servers/test_virtual_interfaces.py
+++ b/tempest/tests/compute/servers/test_virtual_interfaces.py
@@ -21,10 +21,13 @@
 from tempest.tests.compute import base
 
 
-class VirtualInterfacesTest(object):
+@attr(type='smoke')
+class VirtualInterfacesTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
-    def setUpClass(self, cls):
+    def setUpClass(cls):
+        super(VirtualInterfacesTestJSON, cls).setUpClass()
         cls.name = rand_name('server')
         cls.client = cls.servers_client
         resp, server = cls.servers_client.create_server(cls.name,
@@ -35,8 +38,9 @@
         cls.servers_client.wait_for_server_status(cls.server_id, 'ACTIVE')
 
     @classmethod
-    def tearDownClass(self, cls):
+    def tearDownClass(cls):
         cls.servers_client.delete_server(cls.server_id)
+        super(VirtualInterfacesTestJSON, cls).tearDownClass()
 
     @attr(type='positive')
     def test_list_virtual_interfaces(self):
@@ -60,28 +64,5 @@
 
 
 @attr(type='smoke')
-class VirtualInterfacesTestJSON(base.BaseComputeTestJSON,
-                                VirtualInterfacesTest):
-    @classmethod
-    def setUpClass(cls):
-        super(VirtualInterfacesTestJSON, cls).setUpClass()
-        VirtualInterfacesTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        VirtualInterfacesTest.tearDownClass(cls)
-        super(VirtualInterfacesTestJSON, cls).tearDownClass()
-
-
-@attr(type='smoke')
-class VirtualInterfacesTestXML(base.BaseComputeTestXML,
-                               VirtualInterfacesTest):
-    @classmethod
-    def setUpClass(cls):
-        super(VirtualInterfacesTestXML, cls).setUpClass()
-        VirtualInterfacesTest.setUpClass(cls)
-
-    @classmethod
-    def tearDownClass(cls):
-        VirtualInterfacesTest.tearDownClass(cls)
-        super(VirtualInterfacesTestXML, cls).tearDownClass()
+class VirtualInterfacesTestXML(VirtualInterfacesTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/test_authorization.py b/tempest/tests/compute/test_authorization.py
index d826d40..52e457d 100644
--- a/tempest/tests/compute/test_authorization.py
+++ b/tempest/tests/compute/test_authorization.py
@@ -22,10 +22,11 @@
 from tempest.common.utils.data_utils import rand_name
 from tempest import exceptions
 from tempest.tests import compute
-from tempest.tests.compute.base import BaseComputeTest
+from tempest.tests.compute import base
 
 
-class AuthorizationTest(BaseComputeTest):
+class AuthorizationTest(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
@@ -243,6 +244,7 @@
             # Reset the base_url...
             self.alt_security_client.base_url = self.saved_base_url
             if resp['status'] is not None:
+                #TODO(afazekas): body not defined
                 self.alt_security_client.delete_security_group(body['id'])
                 self.fail("Create Security Group request should not happen if"
                           "the tenant id does not match the current user")
@@ -283,7 +285,7 @@
             self.alt_security_client.base_url = self.saved_base_url
             if resp['status'] is not None:
                 self.alt_security_client.delete_security_group_rule(
-                                        body['id'])
+                                        body['id'])  # BUG
                 self.fail("Create security group rule request should not "
                           "happen if the tenant id does not match the"
                           " current user")
diff --git a/tempest/tests/compute/test_extensions.py b/tempest/tests/compute/test_extensions.py
index 36a04d2..2c13fb9 100644
--- a/tempest/tests/compute/test_extensions.py
+++ b/tempest/tests/compute/test_extensions.py
@@ -20,27 +20,16 @@
 from tempest.tests.compute import base
 
 
-class ExtensionsTestBase(object):
+class ExtensionsTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
     @attr(type='positive')
     def test_list_extensions(self):
         # List of all extensions
-        resp, extensions = self.client.list_extensions()
+        resp, extensions = self.extensions_client.list_extensions()
         self.assertTrue("extensions" in extensions)
         self.assertEqual(200, resp.status)
 
 
-class ExtensionsTestJSON(base.BaseComputeTest, ExtensionsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(ExtensionsTestJSON, cls).setUpClass()
-        cls.client = cls.extensions_client
-
-
-class ExtensionsTestXML(base.BaseComputeTestXML, ExtensionsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(ExtensionsTestXML, cls).setUpClass()
-        cls.client = cls.extensions_client
+class ExtensionsTestXML(ExtensionsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/test_live_block_migration.py b/tempest/tests/compute/test_live_block_migration.py
index 6449ddc..078026a 100644
--- a/tempest/tests/compute/test_live_block_migration.py
+++ b/tempest/tests/compute/test_live_block_migration.py
@@ -30,6 +30,7 @@
 
 @attr(category='live-migration')
 class LiveBlockMigrationTest(base.BaseComputeTest):
+    _interface = 'json'
 
     live_migration_available = (
         config.TempestConfig().compute.live_migration_available)
diff --git a/tempest/tests/compute/test_quotas.py b/tempest/tests/compute/test_quotas.py
index c2ad358..dbff275 100644
--- a/tempest/tests/compute/test_quotas.py
+++ b/tempest/tests/compute/test_quotas.py
@@ -19,10 +19,12 @@
 from tempest.tests.compute import base
 
 
-class QuotasTestBase(object):
+class QuotasTestJSON(base.BaseComputeTest):
+    _interface = 'json'
 
     @classmethod
     def setUpClass(cls):
+        super(QuotasTestJSON, cls).setUpClass()
         cls.client = cls.quotas_client
         cls.admin_client = cls._get_identity_admin_client()
         resp, tenants = cls.admin_client.list_tenants()
@@ -47,17 +49,5 @@
             self.fail("Quota set for tenant did not have default limits")
 
 
-class QuotasTestJSON(QuotasTestBase, base.BaseComputeTestJSON):
-
-    @classmethod
-    def setUpClass(cls):
-        base.BaseComputeTestJSON.setUpClass()
-        super(QuotasTestJSON, cls).setUpClass()
-
-
-class QuotasTestXML(QuotasTestBase, base.BaseComputeTestXML):
-
-    @classmethod
-    def setUpClass(cls):
-        base.BaseComputeTestXML.setUpClass()
-        super(QuotasTestXML, cls).setUpClass()
+class QuotasTestXML(QuotasTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/volumes/test_attach_volume.py b/tempest/tests/compute/volumes/test_attach_volume.py
index 1aed833..2679312 100644
--- a/tempest/tests/compute/volumes/test_attach_volume.py
+++ b/tempest/tests/compute/volumes/test_attach_volume.py
@@ -24,12 +24,13 @@
 from tempest.tests.compute import base
 
 
-class AttachVolumeTest(object):
-
+class AttachVolumeTestJSON(base.BaseComputeTest):
+    _interface = 'json'
     run_ssh = tempest.config.TempestConfig().compute.run_ssh
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
+        super(AttachVolumeTestJSON, cls).setUpClass()
         cls.device = 'vdb'
 
     def _detach(self, server_id, volume_id):
@@ -106,17 +107,5 @@
             self._delete(server['id'], volume['id'])
 
 
-class TestAttachVolumeJSON(base.BaseComputeTestJSON,
-                           AttachVolumeTest):
-    @classmethod
-    def setUpClass(cls):
-        super(TestAttachVolumeJSON, cls).setUpClass()
-        AttachVolumeTest.setUpClass(cls)
-
-
-class TestAttachVolumeXML(base.BaseComputeTestXML,
-                          AttachVolumeTest):
-    @classmethod
-    def setUpClass(cls):
-        super(TestAttachVolumeXML, cls).setUpClass()
-        AttachVolumeTest.setUpClass(cls)
+class AttachVolumeTestXML(AttachVolumeTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/volumes/test_volumes_get.py b/tempest/tests/compute/volumes/test_volumes_get.py
index edbfc32..65d2d45 100644
--- a/tempest/tests/compute/volumes/test_volumes_get.py
+++ b/tempest/tests/compute/volumes/test_volumes_get.py
@@ -20,7 +20,14 @@
 from tempest.tests.compute import base
 
 
-class VolumesGetTestBase(object):
+class VolumesGetTestJSON(base.BaseComputeTest):
+
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(VolumesGetTestJSON, cls).setUpClass()
+        cls.client = cls.volumes_extensions_client
 
     @attr(type='smoke')
     def test_volume_create_get_delete(self):
@@ -94,17 +101,5 @@
             self.client.wait_for_resource_deletion(volume['id'])
 
 
-class VolumesGetTestXML(base.BaseComputeTestXML, VolumesGetTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "xml"
-        super(VolumesGetTestXML, cls).setUpClass()
-        cls.client = cls.volumes_extensions_client
-
-
-class VolumesGetTestJSON(base.BaseComputeTestJSON, VolumesGetTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "json"
-        super(VolumesGetTestJSON, cls).setUpClass()
-        cls.client = cls.volumes_extensions_client
+class VolumesGetTestXML(VolumesGetTestJSON):
+    _interface = "xml"
diff --git a/tempest/tests/compute/volumes/test_volumes_list.py b/tempest/tests/compute/volumes/test_volumes_list.py
index cc690a5..ffd6a8c 100644
--- a/tempest/tests/compute/volumes/test_volumes_list.py
+++ b/tempest/tests/compute/volumes/test_volumes_list.py
@@ -20,7 +20,7 @@
 from tempest.tests.compute import base
 
 
-class VolumesTestBase(object):
+class VolumesTestJSON(base.BaseComputeTest):
 
     """
     This test creates a number of 1G volumes. To run successfully,
@@ -30,87 +30,10 @@
     VOLUME_BACKING_FILE_SIZE is atleast 4G in your localrc
     """
 
-    def test_volume_list(self):
-        # Should return the list of Volumes
-        # Fetch all Volumes
-        resp, fetched_list = self.client.list_volumes()
-        self.assertEqual(200, resp.status)
-        # Now check if all the Volumes created in setup are in fetched list
-        missing_volumes = [
-            v for v in self.volume_list if v not in fetched_list
-        ]
+    _interface = 'json'
 
-        self.assertFalse(missing_volumes,
-                         "Failed to find volume %s in fetched list" %
-                         ', '.join(m_vol['displayName']
-                                   for m_vol in missing_volumes))
-
-    def test_volume_list_with_details(self):
-        # Should return the list of Volumes with details
-        #Fetch all Volumes
-        resp, fetched_list = self.client.list_volumes_with_detail()
-        self.assertEqual(200, resp.status)
-        #Now check if all the Volumes created in setup are in fetched list
-        missing_volumes = [
-            v for v in self.volume_list if v not in fetched_list
-        ]
-
-        self.assertFalse(missing_volumes,
-                         "Failed to find volume %s in fetched list" %
-                         ', '.join(m_vol['displayName']
-                                   for m_vol in missing_volumes))
-
-
-class VolumesTestXML(base.BaseComputeTestXML, VolumesTestBase):
     @classmethod
     def setUpClass(cls):
-        cls._interface = 'xml'
-        super(VolumesTestXML, cls).setUpClass()
-        cls.client = cls.volumes_extensions_client
-        # Create 3 Volumes
-        cls.volume_list = list()
-        cls.volume_id_list = list()
-        for i in range(3):
-            v_name = rand_name('volume')
-            metadata = {'Type': 'work'}
-            v_name += cls._interface
-            try:
-                resp, volume = cls.client.create_volume(size=1,
-                                                        display_name=v_name,
-                                                        metadata=metadata)
-                cls.client.wait_for_volume_status(volume['id'], 'available')
-                resp, volume = cls.client.get_volume(volume['id'])
-                cls.volume_list.append(volume)
-                cls.volume_id_list.append(volume['id'])
-            except Exception:
-                if cls.volume_list:
-                    # We could not create all the volumes, though we were able
-                    # to create *some* of the volumes. This is typically
-                    # because the backing file size of the volume group is
-                    # too small. So, here, we clean up whatever we did manage
-                    # to create and raise a SkipTest
-                    for volume in cls.volume_list:
-                        cls.client.delete_volume(volume)
-                    msg = ("Failed to create ALL necessary volumes to run "
-                           "test. This typically means that the backing file "
-                           "size of the nova-volumes group is too small to "
-                           "create the 3 volumes needed by this test case")
-                    raise cls.skipException(msg)
-                raise
-
-    @classmethod
-    def tearDownClass(cls):
-        # Delete the created Volumes
-        for volume in cls.volume_list:
-            resp, _ = cls.client.delete_volume(volume['id'])
-            cls.client.wait_for_resource_deletion(volume['id'])
-        super(VolumesTestXML, cls).tearDownClass()
-
-
-class VolumesTestJSON(base.BaseComputeTestJSON, VolumesTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = 'json'
         super(VolumesTestJSON, cls).setUpClass()
         cls.client = cls.volumes_extensions_client
         # Create 3 Volumes
@@ -151,3 +74,37 @@
             resp, _ = cls.client.delete_volume(volume['id'])
             cls.client.wait_for_resource_deletion(volume['id'])
         super(VolumesTestJSON, cls).tearDownClass()
+
+    def test_volume_list(self):
+        # Should return the list of Volumes
+        # Fetch all Volumes
+        resp, fetched_list = self.client.list_volumes()
+        self.assertEqual(200, resp.status)
+        # Now check if all the Volumes created in setup are in fetched list
+        missing_volumes = [
+            v for v in self.volume_list if v not in fetched_list
+        ]
+
+        self.assertFalse(missing_volumes,
+                         "Failed to find volume %s in fetched list" %
+                         ', '.join(m_vol['displayName']
+                                   for m_vol in missing_volumes))
+
+    def test_volume_list_with_details(self):
+        # Should return the list of Volumes with details
+        #Fetch all Volumes
+        resp, fetched_list = self.client.list_volumes_with_detail()
+        self.assertEqual(200, resp.status)
+        #Now check if all the Volumes created in setup are in fetched list
+        missing_volumes = [
+            v for v in self.volume_list if v not in fetched_list
+        ]
+
+        self.assertFalse(missing_volumes,
+                         "Failed to find volume %s in fetched list" %
+                         ', '.join(m_vol['displayName']
+                                   for m_vol in missing_volumes))
+
+
+class VolumesTestXML(VolumesTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/compute/volumes/test_volumes_negative.py b/tempest/tests/compute/volumes/test_volumes_negative.py
index b24c240..c0fa565 100644
--- a/tempest/tests/compute/volumes/test_volumes_negative.py
+++ b/tempest/tests/compute/volumes/test_volumes_negative.py
@@ -20,7 +20,13 @@
 from tempest.tests.compute import base
 
 
-class VolumesNegativeTestBase(object):
+class VolumesNegativeTest(base.BaseComputeTest):
+    _interface = 'json'
+
+    @classmethod
+    def setUpClass(cls):
+        super(VolumesNegativeTest, cls).setUpClass()
+        cls.client = cls.volumes_extensions_client
 
     def test_volume_get_nonexistant_volume_id(self):
         # Negative: Should not be able to get details of nonexistant volume
@@ -104,19 +110,5 @@
         self.assertRaises(exceptions.NotFound, self.client.delete_volume, '')
 
 
-class VolumesNegativeTestXML(base.BaseComputeTestXML,
-                             VolumesNegativeTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "xml"
-        super(VolumesNegativeTestXML, cls).setUpClass()
-        cls.client = cls.volumes_extensions_client
-
-
-class VolumesNegativeTestJSON(base.BaseComputeTestJSON,
-                              VolumesNegativeTestBase):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "json"
-        super(VolumesNegativeTestJSON, cls).setUpClass()
-        cls.client = cls.volumes_extensions_client
+class VolumesNegativeTestXML(VolumesNegativeTest):
+    _interface = "xml"