summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Basnight <mbasnight@gmail.com>2012-03-07 22:32:23 -0600
committerMichael Basnight <mbasnight@gmail.com>2012-03-07 22:33:10 -0600
commit5c6bccf1c57b06a19845c696c19274ae9f080104 (patch)
tree90a9181a9b7a035acd0439b0b1c449c378ebd8f0
parent4e4f793e0becb19d77cf137587adb9944a15f5f8 (diff)
fixes lp#949648 change belongsTo validate to name
Change-Id: I3d36290ad95a0440c006e2daff5b831be62957ae
-rw-r--r--keystone/service.py2
-rw-r--r--tests/test_content_types.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/keystone/service.py b/keystone/service.py
index a92dc15a..9acee83b 100644
--- a/keystone/service.py
+++ b/keystone/service.py
@@ -365,7 +365,7 @@ class TokenController(wsgi.Application):
token_id=token_id)
if belongs_to:
- assert token_ref['tenant']['id'] == belongs_to
+ assert token_ref['tenant']['name'] == belongs_to
return token_ref
diff --git a/tests/test_content_types.py b/tests/test_content_types.py
index d98330a4..dc632abc 100644
--- a/tests/test_content_types.py
+++ b/tests/test_content_types.py
@@ -355,7 +355,7 @@ class CoreApiTests(object):
def test_validate_token_belongs_to(self):
token = self.get_scoped_token()
path = ('/v2.0/tokens/%s?belongs_to=%s'
- % (token, self.tenant_bar['id']))
+ % (token, self.tenant_bar['name']))
r = self.admin_request(path=path,token=token)
self.assertValidAuthenticationResponse(r,
require_service_catalog=True)