summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJamie Lennox <jamielennox@redhat.com>2014-08-31 20:48:46 +1000
committerJamie Lennox <jamielennox@redhat.com>2014-08-31 21:38:05 +1000
commit1643f7da32b1f729f12d042565d8c67f10f91b8c (patch)
treedad8a52fc46fcc99f9bdfd4c14b314c8ee04ae3c
parent46695565d3bcc5cf9bce23711ec6eca458191898 (diff)
downloadpython-keystoneclient-1643f7da32b1f729f12d042565d8c67f10f91b8c.tar.gz
Fix test mistake with requests-mock
body= parameters are supposed to be io objects. This is obviously during the conversion from HTTPretty. Change-Id: Ia8ec9294e054e2231aa4a5e2633e2b7d5d15066a Closes-Bug: #1363632
-rw-r--r--keystoneclient/tests/auth/test_identity_common.py2
-rw-r--r--keystoneclient/tests/v2_0/test_auth.py2
2 files changed, 2 insertions, 2 deletions
diff --git a/keystoneclient/tests/auth/test_identity_common.py b/keystoneclient/tests/auth/test_identity_common.py
index 8c5499c..b8ff8da 100644
--- a/keystoneclient/tests/auth/test_identity_common.py
+++ b/keystoneclient/tests/auth/test_identity_common.py
@@ -191,7 +191,7 @@ class CommonIdentityTests(object):
body = 'SUCCESS'
self.stub_url('GET', ['path'],
- base_url=self.TEST_COMPUTE_ADMIN, body=body)
+ base_url=self.TEST_COMPUTE_ADMIN, text=body)
a = self.create_auth_plugin(**kwargs)
a.auth_ref = expired_auth_ref
diff --git a/keystoneclient/tests/v2_0/test_auth.py b/keystoneclient/tests/v2_0/test_auth.py
index 0c42699..cdf05f4 100644
--- a/keystoneclient/tests/v2_0/test_auth.py
+++ b/keystoneclient/tests/v2_0/test_auth.py
@@ -101,7 +101,7 @@ class AuthenticateAgainstKeystoneTests(utils.TestCase):
self.assertRequestBodyIs(json=self.TEST_REQUEST_BODY)
def test_auth_redirect(self):
- self.stub_auth(status_code=305, body='Use Proxy',
+ self.stub_auth(status_code=305, text='Use Proxy',
headers={'Location': self.TEST_ADMIN_URL + "/tokens"})
self.stub_auth(base_url=self.TEST_ADMIN_URL,