diff --git a/stress/config.py b/stress/config.py
index ca86ce5..25cb910 100755
--- a/stress/config.py
+++ b/stress/config.py
@@ -12,8 +12,6 @@
 #    See the License for the specific language governing permissions and
 #    limitations under the License.
 
-import ConfigParser
-
 
 class StressConfig(object):
     """Provides configuration information for whitebox stress tests."""
@@ -21,33 +19,27 @@
     def __init__(self, conf):
         self.conf = conf
 
-    def get(self, item_name, default_value=None):
-        try:
-            return self.conf.get("stress", item_name)
-        except (ConfigParser.NoSectionError, ConfigParser.NoOptionError):
-            return default_value
-
     @property
     def host_private_key_path(self):
         """Path to ssh key for logging into compute nodes."""
-        return self.get("host_private_key_path", None)
+        return self.conf.compute.path_to_private_key
 
     @property
     def host_admin_user(self):
         """Username for logging into compute nodes."""
-        return self.get("host_admin_user", None)
+        return self.conf.compute.ssh_user
 
     @property
     def nova_logdir(self):
         """Directory containing log files on the compute nodes."""
-        return self.get("nova_logdir", None)
+        return self.conf.stress.nova_logdir
 
     @property
     def controller(self):
         """Controller host."""
-        return self.get("controller", None)
+        return self.conf.stress.controller
 
     @property
     def max_instances(self):
         """Maximum number of instances to create during test."""
-        return self.get("max_instances", 16)
+        return self.conf.stress.max_instances
diff --git a/stress/driver.py b/stress/driver.py
index 8dc88cf..f80e765 100644
--- a/stress/driver.py
+++ b/stress/driver.py
@@ -18,6 +18,7 @@
 import datetime
 import random
 import time
+from urlparse import urlparse
 
 from config import StressConfig
 from state import ClusterState
@@ -162,7 +163,7 @@
                                    (default: 32)
                     `seed`       = random seed (default: None)
     """
-    stress_config = StressConfig(manager.config._conf)
+    stress_config = StressConfig(manager.config)
     # get keyword arguments
     duration = kwargs.get('duration', datetime.timedelta(seconds=10))
     seed = kwargs.get('seed', None)
@@ -173,7 +174,8 @@
     keypath = stress_config.host_private_key_path
     user = stress_config.host_admin_user
     logdir = stress_config.nova_logdir
-    computes = _get_compute_nodes(keypath, user, manager.config.identity.host)
+    host = urlparse(manager.config.identity.uri).hostname
+    computes = _get_compute_nodes(keypath, user, host)
     stress.utils.execute_on_all(keypath, user, computes,
                                 "rm -f %s/*.log" % logdir)
     random.seed(seed)
diff --git a/tempest/clients.py b/tempest/clients.py
index 7d314f3..ef07d9c 100644
--- a/tempest/clients.py
+++ b/tempest/clients.py
@@ -25,6 +25,7 @@
 from tempest.services.compute.json.flavors_client import FlavorsClientJSON
 from tempest.services.compute.json.floating_ips_client import \
     FloatingIPsClientJSON
+from tempest.services.compute.json.hosts_client import HostsClientJSON
 from tempest.services.compute.json.images_client import ImagesClientJSON
 from tempest.services.compute.json.keypairs_client import KeyPairsClientJSON
 from tempest.services.compute.json.limits_client import LimitsClientJSON
@@ -211,6 +212,7 @@
             msg = "Unsupported interface type `%s'" % interface
             raise exceptions.InvalidConfiguration(msg)
         self.network_client = NetworkClient(*client_args)
+        self.hosts_client = HostsClientJSON(*client_args)
         self.account_client = AccountClient(*client_args)
         self.image_client = ImageClientJSON(*client_args)
         self.container_client = ContainerClient(*client_args)
diff --git a/tempest/config.py b/tempest/config.py
index c982dee..c0e25c7 100644
--- a/tempest/config.py
+++ b/tempest/config.py
@@ -382,6 +382,26 @@
     for opt in BotoConfig:
         conf.register_opt(opt, group='boto')
 
+stress_group = cfg.OptGroup(name='stress', title='Stress Test Options')
+
+StressGroup = [
+    cfg.StrOpt('nova_logdir',
+               default=None,
+               help='Directory containing log files on the compute nodes'),
+    cfg.IntOpt('max_instances',
+               default=16,
+               help='Maximum number of instances to create during test.'),
+    cfg.StrOpt('controller',
+               default=None,
+               help='Controller host.')
+]
+
+
+def register_stress_opts(conf):
+    conf.register_group(stress_group)
+    for opt in StressGroup:
+        conf.register_opt(opt, group='stress')
+
 
 @singleton
 class TempestConfig:
@@ -426,6 +446,7 @@
         register_object_storage_opts(cfg.CONF)
         register_boto_opts(cfg.CONF)
         register_compute_admin_opts(cfg.CONF)
+        register_stress_opts(cfg.CONF)
         self.compute = cfg.CONF.compute
         self.whitebox = cfg.CONF.whitebox
         self.identity = cfg.CONF.identity
@@ -435,6 +456,7 @@
         self.object_storage = cfg.CONF['object-storage']
         self.boto = cfg.CONF.boto
         self.compute_admin = cfg.CONF['compute-admin']
+        self.stress = cfg.CONF.stress
         if not self.compute_admin.username:
             self.compute_admin.username = self.identity.admin_username
             self.compute_admin.password = self.identity.admin_password
diff --git a/tempest/tests/compute/base.py b/tempest/tests/compute/base.py
index 2e5b4fe..94fff13 100644
--- a/tempest/tests/compute/base.py
+++ b/tempest/tests/compute/base.py
@@ -173,36 +173,21 @@
         cls.clear_isolated_creds()
 
     @classmethod
-    def create_server(cls, image_id=None, flavor=None):
+    def create_server(cls, **kwargs):
         """Wrapper utility that returns a test server."""
-        server_name = rand_name(cls.__name__ + "-instance")
-
-        if not flavor:
-            flavor = cls.flavor_ref
-        if not image_id:
-            image_id = cls.image_ref
+        name = rand_name(cls.__name__ + "-instance")
+        if 'name' in kwargs:
+            name = kwargs.pop('name')
+        flavor = kwargs.get('flavor', cls.flavor_ref)
+        image_id = kwargs.get('image_id', cls.image_ref)
 
         resp, server = cls.servers_client.create_server(
-                                                server_name, image_id, flavor)
-        cls.servers_client.wait_for_server_status(server['id'], 'ACTIVE')
-        cls.servers.append(server)
-        return server
+            name, image_id, flavor, **kwargs)
 
-    @classmethod
-    def create_server_with_extras(cls, name, image_id=None,
-                                  flavor=None, **kwargs):
-        # TODO(sdague) transitional function because many
-        # server tests were using extra args and resp so can't
-        # easily be ported to create_server. Will be merged
-        # later
-        if not flavor:
-            flavor = cls.flavor_ref
-        if not image_id:
-            image_id = cls.image_ref
+        if 'wait_until' in kwargs:
+            cls.servers_client.wait_for_server_status(
+                server['id'], kwargs['wait_until'])
 
-        resp, server = cls.servers_client.create_server(name,
-                                                        image_id, flavor,
-                                                        **kwargs)
         cls.servers.append(server)
         return resp, server
 
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 ffff1f7..0f63016 100644
--- a/tempest/tests/compute/floating_ips/test_floating_ips_actions.py
+++ b/tempest/tests/compute/floating_ips/test_floating_ips_actions.py
@@ -176,7 +176,7 @@
             self.client.disassociate_floating_ip_from_server(
                 self.floating_ip,
                 self.server_id)
-        except exceptions.NotFound:
+        except (exceptions.NotFound, exceptions.BadRequest):
             pass
         else:
             self.fail('The floating IP should be associated to the second '
diff --git a/tempest/tests/compute/images/test_images.py b/tempest/tests/compute/images/test_images.py
index d8d38aa..1e90202 100644
--- a/tempest/tests/compute/images/test_images.py
+++ b/tempest/tests/compute/images/test_images.py
@@ -51,12 +51,6 @@
 
     def tearDown(self):
         """Terminate test instances created after a test is executed."""
-        for server in self.servers:
-            resp, body = self.servers_client.delete_server(server['id'])
-            if resp['status'] == '204':
-                self.servers.remove(server)
-                self.servers_client.wait_for_server_termination(server['id'])
-
         for image_id in self.image_ids:
             self.client.delete_image(image_id)
             self.image_ids.remove(image_id)
@@ -65,11 +59,7 @@
     @attr(type='negative')
     def test_create_image_from_deleted_server(self):
         # An image should not be created if the server instance is removed
-        server_name = rand_name('server')
-        resp, server = self.servers_client.create_server(server_name,
-                                                         self.image_ref,
-                                                         self.flavor_ref)
-        self.servers_client.wait_for_server_status(server['id'], 'ACTIVE')
+        resp, server = self.create_server(wait_until='ACTIVE')
 
         # Delete server before trying to create server
         self.servers_client.delete_server(server['id'])
@@ -114,7 +104,7 @@
     @attr(type='negative')
     def test_create_image_when_server_is_terminating(self):
         # Return an error when creating image of server that is terminating
-        server = self.create_server()
+        resp, server = self.create_server(wait_until='ACTIVE')
         self.servers_client.delete_server(server['id'])
 
         snapshot_name = rand_name('test-snap-')
@@ -124,11 +114,7 @@
     @attr(type='negative')
     def test_create_image_when_server_is_building(self):
         # Return error when creating an image of a server that is building
-        server_name = rand_name('test-vm-')
-        resp, server = self.servers_client.create_server(server_name,
-                                                         self.image_ref,
-                                                         self.flavor_ref)
-        self.servers.append(server)
+        resp, server = self.create_server(wait_until='BUILD')
         snapshot_name = rand_name('test-snap-')
         self.assertRaises(exceptions.Duplicate, self.client.create_image,
                           server['id'], snapshot_name)
@@ -137,7 +123,7 @@
     @attr(type='negative')
     def test_create_image_when_server_is_rebooting(self):
         # Return error when creating an image of server that is rebooting
-        server = self.create_server()
+        resp, server = self.create_server()
         self.servers_client.reboot(server['id'], 'HARD')
 
         snapshot_name = rand_name('test-snap-')
diff --git a/tempest/tests/compute/images/test_images_oneserver.py b/tempest/tests/compute/images/test_images_oneserver.py
index 34ea868..6d3f043 100644
--- a/tempest/tests/compute/images/test_images_oneserver.py
+++ b/tempest/tests/compute/images/test_images_oneserver.py
@@ -41,7 +41,7 @@
         super(ImagesOneServerTestJSON, cls).setUpClass()
         cls.client = cls.images_client
         cls.servers_client = cls.servers_client
-        cls.server = cls.create_server()
+        resp, cls.server = cls.create_server(wait_until='ACTIVE')
 
         cls.image_ids = []
 
diff --git a/tempest/tests/compute/images/test_list_image_filters.py b/tempest/tests/compute/images/test_list_image_filters.py
index 56f388d..5038a65 100644
--- a/tempest/tests/compute/images/test_list_image_filters.py
+++ b/tempest/tests/compute/images/test_list_image_filters.py
@@ -30,16 +30,10 @@
         super(ListImageFiltersTest, cls).setUpClass()
         cls.client = cls.images_client
 
-        name = rand_name('server')
-        resp, cls.server1 = cls.servers_client.create_server(name,
-                                                             cls.image_ref,
-                                                             cls.flavor_ref)
-        name = rand_name('server')
-        resp, cls.server2 = cls.servers_client.create_server(name,
-                                                             cls.image_ref,
-                                                             cls.flavor_ref)
+        resp, cls.server1 = cls.create_server()
+        resp, cls.server2 = cls.create_server(wait_until='ACTIVE')
+        # NOTE(sdague) this is faster than doing the sync wait_util on both
         cls.servers_client.wait_for_server_status(cls.server1['id'], 'ACTIVE')
-        cls.servers_client.wait_for_server_status(cls.server2['id'], 'ACTIVE')
 
         # Create images to be used in the filter tests
         image1_name = rand_name('image')
@@ -71,8 +65,6 @@
         cls.client.delete_image(cls.image1_id)
         cls.client.delete_image(cls.image2_id)
         cls.client.delete_image(cls.image3_id)
-        cls.servers_client.delete_server(cls.server1['id'])
-        cls.servers_client.delete_server(cls.server2['id'])
         super(ListImageFiltersTest, cls).tearDownClass()
 
     @attr(type='negative')
diff --git a/tempest/tests/compute/servers/test_disk_config.py b/tempest/tests/compute/servers/test_disk_config.py
index 671abf9..3a1ec20 100644
--- a/tempest/tests/compute/servers/test_disk_config.py
+++ b/tempest/tests/compute/servers/test_disk_config.py
@@ -37,14 +37,8 @@
     @attr(type='positive')
     def test_rebuild_server_with_manual_disk_config(self):
         # A server should be rebuilt using the manual disk config option
-        name = rand_name('server')
-        resp, server = self.create_server_with_extras(name,
-                                                      self.image_ref,
-                                                      self.flavor_ref,
-                                                      disk_config='AUTO')
-
-        #Wait for the server to become active
-        self.client.wait_for_server_status(server['id'], 'ACTIVE')
+        resp, server = self.create_server(disk_config='AUTO',
+                                          wait_until='ACTIVE')
 
         #Verify the specified attributes are set correctly
         resp, server = self.client.get_server(server['id'])
@@ -67,14 +61,8 @@
     @attr(type='positive')
     def test_rebuild_server_with_auto_disk_config(self):
         # A server should be rebuilt using the auto disk config option
-        name = rand_name('server')
-        resp, server = self.create_server_with_extras(name,
-                                                      self.image_ref,
-                                                      self.flavor_ref,
-                                                      disk_config='MANUAL')
-
-        #Wait for the server to become active
-        self.client.wait_for_server_status(server['id'], 'ACTIVE')
+        resp, server = self.create_server(disk_config='MANUAL',
+                                          wait_until='ACTIVE')
 
         #Verify the specified attributes are set correctly
         resp, server = self.client.get_server(server['id'])
@@ -98,14 +86,8 @@
     @testtools.skipUnless(compute.RESIZE_AVAILABLE, 'Resize not available.')
     def test_resize_server_from_manual_to_auto(self):
         # A server should be resized from manual to auto disk config
-        name = rand_name('server')
-        resp, server = self.create_server_with_extras(name,
-                                                      self.image_ref,
-                                                      self.flavor_ref,
-                                                      disk_config='MANUAL')
-
-        #Wait for the server to become active
-        self.client.wait_for_server_status(server['id'], 'ACTIVE')
+        resp, server = self.create_server(disk_config='MANUAL',
+                                          wait_until='ACTIVE')
 
         #Resize with auto option
         self.client.resize(server['id'], self.flavor_ref_alt,
@@ -124,14 +106,8 @@
     @testtools.skipUnless(compute.RESIZE_AVAILABLE, 'Resize not available.')
     def test_resize_server_from_auto_to_manual(self):
         # A server should be resized from auto to manual disk config
-        name = rand_name('server')
-        resp, server = self.create_server_with_extras(name,
-                                                      self.image_ref,
-                                                      self.flavor_ref,
-                                                      disk_config='AUTO')
-
-        #Wait for the server to become active
-        self.client.wait_for_server_status(server['id'], 'ACTIVE')
+        resp, server = self.create_server(disk_config='AUTO',
+                                          wait_until='ACTIVE')
 
         #Resize with manual option
         self.client.resize(server['id'], self.flavor_ref_alt,
diff --git a/tempest/tests/compute/servers/test_list_servers_negative.py b/tempest/tests/compute/servers/test_list_servers_negative.py
index 320f920..01b11e0 100644
--- a/tempest/tests/compute/servers/test_list_servers_negative.py
+++ b/tempest/tests/compute/servers/test_list_servers_negative.py
@@ -78,10 +78,10 @@
         cls.existing_fixtures = []
         cls.deleted_fixtures = []
         for x in xrange(2):
-            srv = cls.create_server()
+            resp, srv = cls.create_server()
             cls.existing_fixtures.append(srv)
 
-        srv = cls.create_server()
+        resp, srv = cls.create_server()
         cls.client.delete_server(srv['id'])
         # We ignore errors on termination because the server may
         # be put into ERROR status on a quick spawn, then delete,
diff --git a/tempest/tests/compute/servers/test_server_actions.py b/tempest/tests/compute/servers/test_server_actions.py
index bc8e843..5046ec2 100644
--- a/tempest/tests/compute/servers/test_server_actions.py
+++ b/tempest/tests/compute/servers/test_server_actions.py
@@ -257,13 +257,9 @@
     def rebuild_servers(cls):
         # Destroy any existing server and creates a new one
         cls.clear_servers()
-        cls.name = rand_name('server')
-        resp, server = cls.create_server_with_extras(cls.name,
-                                                     cls.image_ref,
-                                                     cls.flavor_ref)
+        resp, server = cls.create_server(wait_until='ACTIVE')
         cls.server_id = server['id']
         cls.password = server['adminPass']
-        cls.client.wait_for_server_status(cls.server_id, 'ACTIVE')
 
 
 class ServerActionsTestXML(ServerActionsTestJSON):
diff --git a/tempest/tests/compute/servers/test_server_metadata.py b/tempest/tests/compute/servers/test_server_metadata.py
index 7896466..4b17fa2 100644
--- a/tempest/tests/compute/servers/test_server_metadata.py
+++ b/tempest/tests/compute/servers/test_server_metadata.py
@@ -83,11 +83,9 @@
         for sz in [256, 257, 511, 1023]:
             key = "k" * sz
             meta = {key: 'data1'}
-            name = rand_name('server')
             self.assertRaises(exceptions.OverLimit,
-                              self.create_server_with_extras,
-                              name, self.image_ref,
-                              self.flavor_ref, meta=meta)
+                              self.create_server,
+                              meta=meta)
 
         # no teardown - all creates should fail
 
@@ -95,11 +93,9 @@
     def test_create_metadata_key_error(self):
         # Blank key should trigger an error.
         meta = {'': 'data1'}
-        name = rand_name('server')
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          name, self.image_ref,
-                          self.flavor_ref, meta=meta)
+                          self.create_server,
+                          meta=meta)
 
     def test_update_server_metadata(self):
         # The server's metadata values should be updated to the
@@ -233,3 +229,12 @@
         self.assertRaises(exceptions.OverLimit,
                           self.client.update_server_metadata,
                           self.server_id, req_metadata)
+
+    @attr(type='negative')
+    def test_update_all_metadata_field_error(self):
+        # Raise a bad request error for blank key.
+        # set_server_metadata will replace all metadata with new value
+        meta = {'': 'data1'}
+        self.assertRaises(exceptions.BadRequest,
+                          self.client.set_server_metadata,
+                          self.server_id, meta=meta)
diff --git a/tempest/tests/compute/servers/test_server_personality.py b/tempest/tests/compute/servers/test_server_personality.py
index 816ca76..0bafc2c 100644
--- a/tempest/tests/compute/servers/test_server_personality.py
+++ b/tempest/tests/compute/servers/test_server_personality.py
@@ -35,7 +35,6 @@
     def test_personality_files_exceed_limit(self):
         # Server creation should fail if greater than the maximum allowed
         # number of files are injected into the server.
-        name = rand_name('server')
         file_contents = 'This is a test file.'
         personality = []
         max_file_limit = \
@@ -45,9 +44,7 @@
             personality.append({'path': path,
                                 'contents': base64.b64encode(file_contents)})
         try:
-            self.create_server_with_extras(name, self.image_ref,
-                                           self.flavor_ref,
-                                           personality=personality)
+            self.create_server(personality=personality)
         except exceptions.OverLimit:
             pass
         else:
@@ -58,7 +55,6 @@
         # Server should be created successfully if maximum allowed number of
         # files is injected into the server during creation.
         try:
-            name = rand_name('server')
             file_contents = 'This is a test file.'
 
             max_file_limit = \
@@ -71,9 +67,7 @@
                     'path': path,
                     'contents': base64.b64encode(file_contents),
                 })
-            resp, server = self.create_server_with_extras(name, self.image_ref,
-                                                          self.flavor_ref,
-                                                          personality=person)
+            resp, server = self.create_server(personality=person)
             self.assertEqual('202', resp['status'])
 
         #Teardown
diff --git a/tempest/tests/compute/servers/test_servers.py b/tempest/tests/compute/servers/test_servers.py
index a912652..a8d28df 100644
--- a/tempest/tests/compute/servers/test_servers.py
+++ b/tempest/tests/compute/servers/test_servers.py
@@ -35,11 +35,7 @@
 
         try:
             server = None
-            name = rand_name('server')
-            resp, server = self.create_server_with_extras(name, self.image_ref,
-                                                          self.flavor_ref,
-                                                          adminPass='test'
-                                                          'password')
+            resp, server = self.create_server(adminPass='testpassword')
 
             #Verify the password is set correctly in the response
             self.assertEqual('testpassword', server['adminPass'])
@@ -52,19 +48,16 @@
     def test_create_with_existing_server_name(self):
         # Creating a server with a name that already exists is allowed
 
+        # TODO(sdague): clear out try, we do cleanup one layer up
         try:
             id1 = None
             id2 = None
             server_name = rand_name('server')
-            resp, server = self.create_server_with_extras(server_name,
-                                                          self.image_ref,
-                                                          self.flavor_ref)
-            self.client.wait_for_server_status(server['id'], 'ACTIVE')
+            resp, server = self.create_server(name=server_name,
+                                              wait_until='ACTIVE')
             id1 = server['id']
-            resp, server = self.create_server_with_extras(server_name,
-                                                          self.image_ref,
-                                                          self.flavor_ref)
-            self.client.wait_for_server_status(server['id'], 'ACTIVE')
+            resp, server = self.create_server(name=server_name,
+                                              wait_until='ACTIVE')
             id2 = server['id']
             self.assertNotEqual(id1, id2, "Did not create a new server")
             resp, server = self.client.get_server(id1)
@@ -86,11 +79,7 @@
             key_name = rand_name('key')
             resp, keypair = self.keypairs_client.create_keypair(key_name)
             resp, body = self.keypairs_client.list_keypairs()
-            server_name = rand_name('server')
-            resp, server = self.create_server_with_extras(server_name,
-                                                          self.image_ref,
-                                                          self.flavor_ref,
-                                                          key_name=key_name)
+            resp, server = self.create_server(key_name=key_name)
             self.assertEqual('202', resp['status'])
             self.client.wait_for_server_status(server['id'], 'ACTIVE')
             resp, server = self.client.get_server(server['id'])
@@ -104,10 +93,7 @@
         # The server name should be changed to the the provided value
         try:
             server = None
-            name = rand_name('server')
-            resp, server = self.create_server_with_extras(name, self.image_ref,
-                                                          self.flavor_ref)
-            self.client.wait_for_server_status(server['id'], 'ACTIVE')
+            resp, server = self.create_server(wait_until='ACTIVE')
 
             #Update the server with a new name
             resp, server = self.client.update_server(server['id'],
@@ -129,10 +115,7 @@
         # The server's access addresses should reflect the provided values
         try:
             server = None
-            name = rand_name('server')
-            resp, server = self.create_server_with_extras(name, self.image_ref,
-                                                          self.flavor_ref)
-            self.client.wait_for_server_status(server['id'], 'ACTIVE')
+            resp, server = self.create_server(wait_until='ACTIVE')
 
             #Update the IPv4 and IPv6 access addresses
             resp, body = self.client.update_server(server['id'],
@@ -153,10 +136,7 @@
 
     def test_delete_server_while_in_building_state(self):
         # Delete a server while it's VM state is Building
-        name = rand_name('server')
-        resp, server = self.create_server_with_extras(name, self.image_ref,
-                                                      self.flavor_ref)
-        self.client.wait_for_server_status(server['id'], 'BUILD')
+        resp, server = self.create_server(wait_until='BUILD')
         resp, _ = self.client.delete_server(server['id'])
         self.assertEqual('204', resp['status'])
 
diff --git a/tempest/tests/compute/servers/test_servers_negative.py b/tempest/tests/compute/servers/test_servers_negative.py
index 80358ec..366b630 100644
--- a/tempest/tests/compute/servers/test_servers_negative.py
+++ b/tempest/tests/compute/servers/test_servers_negative.py
@@ -41,8 +41,8 @@
         # Create a server with name parameter empty
 
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          '', self.image_ref, self.flavor_ref)
+                          self.create_server,
+                          name='')
 
     @attr(type='negative')
     def test_personality_file_contents_not_encoded(self):
@@ -53,8 +53,7 @@
                    'contents': file_contents}]
 
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          'fail', self.image_ref, self.flavor_ref,
+                          self.create_server,
                           personality=person)
 
     @attr(type='negative')
@@ -62,16 +61,16 @@
         # Create a server with an unknown image
 
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          'fail', -1, self.flavor_ref)
+                          self.create_server,
+                          image_id=-1)
 
     @attr(type='negative')
     def test_create_with_invalid_flavor(self):
         # Create a server with an unknown flavor
 
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          'fail', self.image_ref, -1)
+                          self.create_server,
+                          flavor=-1,)
 
     @attr(type='negative')
     def test_invalid_access_ip_v4_address(self):
@@ -79,8 +78,7 @@
 
         IPv4 = '1.1.1.1.1.1'
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras, "fail",
-                          self.image_ref, self.flavor_ref, accessIPv4=IPv4)
+                          self.create_server, accessIPv4=IPv4)
 
     @attr(type='negative')
     def test_invalid_ip_v6_address(self):
@@ -89,18 +87,13 @@
         IPv6 = 'notvalid'
 
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras, "fail",
-                          self.image_ref, self.flavor_ref, accessIPv6=IPv6)
+                          self.create_server, accessIPv6=IPv6)
 
     @attr(type='negative')
     def test_reboot_deleted_server(self):
         # Reboot a deleted server
-
-        self.name = rand_name('server')
-        resp, create_server = self.create_server_with_extras(self.name,
-                                                             self.image_ref,
-                                                             self.flavor_ref)
-        self.server_id = create_server['id']
+        resp, server = self.create_server()
+        self.server_id = server['id']
         self.client.delete_server(self.server_id)
         self.client.wait_for_server_termination(self.server_id)
         self.assertRaises(exceptions.NotFound, self.client.reboot,
@@ -110,11 +103,8 @@
     def test_rebuild_deleted_server(self):
         # Rebuild a deleted server
 
-        self.name = rand_name('server')
-        resp, create_server = self.create_server_with_extras(self.name,
-                                                             self.image_ref,
-                                                             self.flavor_ref)
-        self.server_id = create_server['id']
+        resp, server = self.create_server()
+        self.server_id = server['id']
         self.client.delete_server(self.server_id)
         self.client.wait_for_server_termination(self.server_id)
 
@@ -128,8 +118,8 @@
 
         server_name = 12345
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          server_name, self.image_ref, self.flavor_ref)
+                          self.create_server,
+                          name=server_name)
 
     @attr(type='negative')
     def test_create_server_name_length_exceeds_256(self):
@@ -137,19 +127,17 @@
 
         server_name = 'a' * 256
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          server_name, self.image_ref, self.flavor_ref)
+                          self.create_server,
+                          name=server_name)
 
     @attr(type='negative')
     def test_create_with_invalid_network_uuid(self):
         # Pass invalid network uuid while creating a server
 
-        server_name = rand_name('server')
         networks = [{'fixed_ip': '10.0.1.1', 'uuid': 'a-b-c-d-e-f-g-h-i-j'}]
 
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          server_name, self.image_ref, self.flavor_ref,
+                          self.create_server,
                           networks=networks)
 
     @attr(type='negative')
@@ -157,21 +145,17 @@
         # Pass a non existant keypair while creating a server
 
         key_name = rand_name('key')
-        server_name = rand_name('server')
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras,
-                          server_name, self.image_ref, self.flavor_ref,
+                          self.create_server,
                           key_name=key_name)
 
     @attr(type='negative')
     def test_create_server_metadata_exceeds_length_limit(self):
         # Pass really long metadata while creating a server
 
-        server_name = rand_name('server')
         metadata = {'a': 'b' * 260}
         self.assertRaises(exceptions.OverLimit,
-                          self.create_server_with_extras,
-                          server_name, self.image_ref, self.flavor_ref,
+                          self.create_server,
                           meta=metadata)
 
     @attr(type='negative')
@@ -252,8 +236,7 @@
 
         security_groups = [{'name': 'does_not_exist'}]
         self.assertRaises(exceptions.BadRequest,
-                          self.create_server_with_extras, 'fail',
-                          self.image_ref, self.flavor_ref,
+                          self.create_server,
                           security_groups=security_groups)
 
     @attr(type='negative')
diff --git a/tempest/tests/compute/test_live_block_migration.py b/tempest/tests/compute/test_live_block_migration.py
index 078026a..dcd6a78 100644
--- a/tempest/tests/compute/test_live_block_migration.py
+++ b/tempest/tests/compute/test_live_block_migration.py
@@ -22,14 +22,12 @@
 
 from tempest import config
 from tempest import exceptions
-from tempest.services.compute.json.hosts_client import HostsClientJSON
-from tempest.services.compute.json.servers_client import ServersClientJSON
 from tempest.test import attr
 from tempest.tests.compute import base
 
 
 @attr(category='live-migration')
-class LiveBlockMigrationTest(base.BaseComputeTest):
+class LiveBlockMigrationTest(base.BaseComputeAdminTest):
     _interface = 'json'
 
     live_migration_available = (
@@ -42,12 +40,8 @@
     def setUpClass(cls):
         super(LiveBlockMigrationTest, cls).setUpClass()
 
-        tenant_name = cls.config.compute_admin.tenant_name
-        cls.admin_hosts_client = HostsClientJSON(
-            *cls._get_client_args(), tenant_name=tenant_name)
-
-        cls.admin_servers_client = ServersClientJSON(
-            *cls._get_client_args(), tenant_name=tenant_name)
+        cls.admin_hosts_client = cls.os_adm.hosts_client
+        cls.admin_servers_client = cls.os_adm.servers_client
 
         cls.created_server_ids = []
 
@@ -102,7 +96,7 @@
     @attr(type='positive')
     @testtools.skipIf(not live_migration_available,
                       'Block Live migration not available')
-    def test_001_live_block_migration(self):
+    def test_live_block_migration(self):
         # Live block migrate an instance to another host
         if len(self._get_compute_hostnames()) < 2:
             raise self.skipTest(
@@ -114,11 +108,10 @@
         self.servers_client.wait_for_server_status(server_id, 'ACTIVE')
         self.assertEquals(target_host, self._get_host_for_server(server_id))
 
-    @attr(type='positive', bug='lp1051881')
     @testtools.skip('Until bug 1051881 is dealt with.')
     @testtools.skipIf(not live_migration_available,
                       'Block Live migration not available')
-    def test_002_invalid_host_for_migration(self):
+    def test_invalid_host_for_migration(self):
         # Migrating to an invalid host should not change the status
 
         server_id = self._get_an_active_server()
diff --git a/tempest/tests/identity/admin/test_roles.py b/tempest/tests/identity/admin/test_roles.py
index 46db4fb..53c5b0d 100644
--- a/tempest/tests/identity/admin/test_roles.py
+++ b/tempest/tests/identity/admin/test_roles.py
@@ -20,11 +20,12 @@
 from tempest.tests.identity import base
 
 
-class RolesTestBase(object):
+class RolesTestJSON(base.BaseIdentityAdminTest):
+    _interface = 'json'
 
-    @staticmethod
+    @classmethod
     def setUpClass(cls):
-
+        super(RolesTestJSON, cls).setUpClass()
         for _ in xrange(5):
             resp, role = cls.client.create_role(rand_name('role-'))
             cls.data.roles.append(role)
@@ -37,6 +38,13 @@
         role = self.get_role_by_name(self.data.test_role)
         return (user, tenant, role)
 
+    def assert_role_in_role_list(self, role, roles):
+        found = False
+        for user_role in roles:
+            if user_role['id'] == role['id']:
+                found = True
+        self.assertTrue(found, "assigned role was not in list")
+
     def test_list_roles(self):
         # Return a list of all roles
         resp, body = self.client.list_roles()
@@ -97,34 +105,6 @@
             pass
         self.client.delete_role(role1_id)
 
-
-class RolesTestJSON(base.BaseIdentityAdminTestJSON,
-                    RolesTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(RolesTestJSON, cls).setUpClass()
-        RolesTestBase.setUpClass(cls)
-
-
-class RolesTestXML(base.BaseIdentityAdminTestXML,
-                   RolesTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(RolesTestXML, cls).setUpClass()
-        RolesTestBase.setUpClass(cls)
-
-
-class UserRolesTestBase(RolesTestBase):
-
-    def assert_role_in_role_list(self, role, roles):
-        found = False
-        for user_role in roles:
-            if user_role['id'] == role['id']:
-                found = True
-        self.assertTrue(found, "assigned role was not in list")
-
     def test_assign_user_role(self):
         # Assign a role to a user on a tenant
         (user, tenant, role) = self._get_role_params()
@@ -267,17 +247,5 @@
                           tenant['id'], 'junk-role-aabbcc11')
 
 
-class UserRolesTestJSON(RolesTestJSON,
-                        UserRolesTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(UserRolesTestJSON, cls).setUpClass()
-
-
-class UserRolesTestXML(RolesTestXML,
-                       UserRolesTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(UserRolesTestXML, cls).setUpClass()
+class RolesTestXML(RolesTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/identity/admin/test_services.py b/tempest/tests/identity/admin/test_services.py
index 77c8e83..caf57bd 100644
--- a/tempest/tests/identity/admin/test_services.py
+++ b/tempest/tests/identity/admin/test_services.py
@@ -21,7 +21,8 @@
 from tempest.tests.identity import base
 
 
-class ServicesTestBase(object):
+class ServicesTestJSON(base.BaseIdentityAdminTest):
+    _interface = 'json'
 
     def test_create_get_delete_service(self):
         # GET Service
@@ -91,14 +92,5 @@
         self.assertFalse(any(found), 'Services failed to delete')
 
 
-class ServicesTestJSON(base.BaseIdentityAdminTestJSON, ServicesTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(ServicesTestJSON, cls).setUpClass()
-
-
-class ServicesTestXML(base.BaseIdentityAdminTestXML,
-                      ServicesTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(ServicesTestXML, cls).setUpClass()
+class ServicesTestXML(ServicesTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/identity/admin/test_tenants.py b/tempest/tests/identity/admin/test_tenants.py
index 6385cec..a3c9246 100644
--- a/tempest/tests/identity/admin/test_tenants.py
+++ b/tempest/tests/identity/admin/test_tenants.py
@@ -21,7 +21,8 @@
 from tempest.tests.identity import base
 
 
-class TenantsTestBase(object):
+class TenantsTestJSON(base.BaseIdentityAdminTest):
+    _interface = 'json'
 
     def test_list_tenants_by_unauthorized_user(self):
         # Non-admin user should not be able to list tenants
@@ -272,16 +273,5 @@
         self.data.tenants.remove(tenant)
 
 
-class TenantsTestJSON(base.BaseIdentityAdminTestJSON,
-                      TenantsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(TenantsTestJSON, cls).setUpClass()
-
-
-class TenantsTestXML(base.BaseIdentityAdminTestXML, TenantsTestBase):
-
-    @classmethod
-    def setUpClass(cls):
-        super(TenantsTestXML, cls).setUpClass()
+class TenantsTestXML(TenantsTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/identity/admin/test_users.py b/tempest/tests/identity/admin/test_users.py
index 67b2517..224272e 100644
--- a/tempest/tests/identity/admin/test_users.py
+++ b/tempest/tests/identity/admin/test_users.py
@@ -23,7 +23,8 @@
 from testtools.matchers._basic import Contains
 
 
-class UsersTestBase(object):
+class UsersTestJSON(base.BaseIdentityAdminTest):
+    _interface = 'json'
 
     alt_user = rand_name('test_user_')
     alt_password = rand_name('pass_')
@@ -338,14 +339,5 @@
                       'tenant ids %s' % fail)
 
 
-class UsersTestJSON(base.BaseIdentityAdminTestJSON,
-                    UsersTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(UsersTestJSON, cls).setUpClass()
-
-
-class UsersTestXML(base.BaseIdentityAdminTestXML, UsersTestBase):
-    @classmethod
-    def setUpClass(cls):
-        super(UsersTestXML, cls).setUpClass()
+class UsersTestXML(UsersTestJSON):
+    _interface = 'xml'
diff --git a/tempest/tests/identity/base.py b/tempest/tests/identity/base.py
index 2c4162c..168b2ff 100644
--- a/tempest/tests/identity/base.py
+++ b/tempest/tests/identity/base.py
@@ -21,7 +21,7 @@
 import tempest.test
 
 
-class BaseIdAdminTest(tempest.test.BaseTestCase):
+class BaseIdentityAdminTest(tempest.test.BaseTestCase):
 
     @classmethod
     def setUpClass(cls):
@@ -68,22 +68,6 @@
             return role[0]
 
 
-class BaseIdentityAdminTestJSON(BaseIdAdminTest):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "json"
-        super(BaseIdentityAdminTestJSON, cls).setUpClass()
-
-BaseIdentityAdminTest = BaseIdentityAdminTestJSON
-
-
-class BaseIdentityAdminTestXML(BaseIdAdminTest):
-    @classmethod
-    def setUpClass(cls):
-        cls._interface = "xml"
-        super(BaseIdentityAdminTestXML, cls).setUpClass()
-
-
 class DataGenerator(object):
 
         def __init__(self, client):
