From 0df93ebd19eae6e44d12572d7924a98ef2d6b022 Mon Sep 17 00:00:00 2001 From: Jesse Andrews Date: Thu, 19 Jan 2012 16:25:26 -0800 Subject: [PATCH] use token_client in token tests --- tests/test_keystoneclient.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/tests/test_keystoneclient.py b/tests/test_keystoneclient.py index a31d8adb6c..1efe550b42 100644 --- a/tests/test_keystoneclient.py +++ b/tests/test_keystoneclient.py @@ -96,21 +96,21 @@ class KcMasterTestCase(CompatTestCase): client = self.get_client() token = client.auth_token token_client = self._client(token=token) - tenants = client.tenants.list() + tenants = token_client.tenants.list() self.assertEquals(tenants[0].id, self.tenant_bar['id']) def test_authenticate_token_tenant_id(self): client = self.get_client() token = client.auth_token token_client = self._client(token=token, tenant_id='bar') - tenants = client.tenants.list() + tenants = token_client.tenants.list() self.assertEquals(tenants[0].id, self.tenant_bar['id']) def test_authenticate_token_tenant_name(self): client = self.get_client() token = client.auth_token token_client = self._client(token=token, tenant_name='BAR') - tenants = client.tenants.list() + tenants = token_client.tenants.list() self.assertEquals(tenants[0].id, self.tenant_bar['id']) # TODO(termie): I'm not really sure that this is testing much @@ -173,7 +173,6 @@ class KcMasterTestCase(CompatTestCase): # use python's scope fall through to leave roleref_ref set break - client.roles.remove_user_from_tenant(self.tenant_baz['id'], self.user_foo['id'], roleref_ref.id) @@ -296,7 +295,7 @@ class KcMasterTestCase(CompatTestCase): two = self.get_client(self.user_two) self.assertRaises(client_exceptions.Unauthorized, two.ec2.delete, self.user_foo['id'], cred.access) - + foo.ec2.delete(self.user_foo['id'], cred.access) def test_service_create_and_delete(self):