diff options
Diffstat (limited to 'python/tests')
| -rwxr-xr-x | python/tests/profiles_tests.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/python/tests/profiles_tests.py b/python/tests/profiles_tests.py index 4e367ad7..6aba8e80 100755 --- a/python/tests/profiles_tests.py +++ b/python/tests/profiles_tests.py @@ -88,7 +88,6 @@ class LoginTestCase(unittest.TestCase): os.path.join(dataDir, 'idp1-la/certificate.pem')) login = lasso.Login(lassoServer) login.init_authn_request(lasso.httpMethodRedirect) - self.failUnlessEqual(login.request_type, lasso.messageTypeAuthnRequest) login.authn_request login.authn_request.protocolProfile = lasso.libProtocolProfileBrwsArt @@ -110,8 +109,9 @@ class LogoutTestCase(unittest.TestCase): logout = lasso.Logout(lassoServer, lasso.providerTypeSp) try: logout.init_request() - except lasso.Error, error: - if error.code != -1: + except RuntimeError, error: + errorCode = int(error.args[0].split(' ', 1)[0]) + if errorCode != -1: raise else: self.fail('logout.init_request without having set identity before should fail') @@ -151,8 +151,8 @@ class DefederationTestCase(unittest.TestCase): # The process_notification_msg should failt but not abort. try: defederation.process_notification_msg('nonLibertyQuery=1', lasso.httpMethodRedirect) - except lasso.Error, error: - pass + except RuntimeError, error: + errorCode = int(error.args[0].split(' ', 1)[0]) else: self.fail('Defederation process_notification_msg should have failed.') |
