Commit 45151289 by Sebastian Annies

let test reflect new return value of verify_cas2. was just user, is no (user,…

let test reflect new return value of verify_cas2. was just user, is no (user, authentication_response)
parent c91b4ddf
...@@ -22,7 +22,7 @@ class backendTest(TestCase): ...@@ -22,7 +22,7 @@ class backendTest(TestCase):
def test_verify_cas2_no_pgt(self): def test_verify_cas2_no_pgt(self):
urllib.urlopen = dummyUrlOpenNoProxyGrantingTicket urllib.urlopen = dummyUrlOpenNoProxyGrantingTicket
settings.CAS_PROXY_CALLBACK = None settings.CAS_PROXY_CALLBACK = None
user = _verify_cas2('ST-jkadfhjksdhjkfh', 'http://dummy') user, authentication_response = _verify_cas2('ST-jkadfhjksdhjkfh', 'http://dummy')
self.assertEqual('sannies', user) self.assertEqual('sannies', user)
def test_verify_cas2_with_pgt(self): def test_verify_cas2_with_pgt(self):
...@@ -33,6 +33,6 @@ class backendTest(TestCase): ...@@ -33,6 +33,6 @@ class backendTest(TestCase):
settings.CAS_PROXY_CALLBACK = "http://dummy2" settings.CAS_PROXY_CALLBACK = "http://dummy2"
prior = PgtIOU.objects.count() prior = PgtIOU.objects.count()
user = _verify_cas2('ST-jkadfhjksdhjkfh', 'http://dummy') user, authentication_response = _verify_cas2('ST-jkadfhjksdhjkfh', 'http://dummy')
self.assertEqual(prior - 1, PgtIOU.objects.count()) # the pgtiou should be used up and deleted self.assertEqual(prior - 1, PgtIOU.objects.count()) # the pgtiou should be used up and deleted
self.assertEqual('sannies', user) self.assertEqual('sannies', user)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment