From eee077c0e2f6e8a05803afb48ad5af4c2d01cde7 Mon Sep 17 00:00:00 2001 From: Emmanuel Raviart Date: Sat, 2 Oct 2004 22:23:57 +0000 Subject: Removed SWIG_Warning which doesn't exist in Swig. Updated Python tests. --- python/tests/profiles_tests.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'python') diff --git a/python/tests/profiles_tests.py b/python/tests/profiles_tests.py index 9607a7e1..060e94cb 100755 --- a/python/tests/profiles_tests.py +++ b/python/tests/profiles_tests.py @@ -143,8 +143,9 @@ class LogoutTestCase(unittest.TestCase): # The processRequestMsg should fail but not abort. try: logout.processRequestMsg('passport=0&lasso=1', lasso.httpMethodRedirect) - except lasso.SyntaxError: - pass + except lasso.Error, error: + if error[0] != lasso.PROFILE_ERROR_INVALID_QUERY: + raise else: self.fail('Logout processRequestMsg should have failed.') @@ -164,8 +165,9 @@ class LogoutTestCase(unittest.TestCase): # The processResponseMsg should fail but not abort. try: logout.processResponseMsg('liberty=&alliance', lasso.httpMethodRedirect) - except lasso.SyntaxError: - pass + except lasso.Error, error: + if error[0] != lasso.PROFILE_ERROR_INVALID_QUERY: + raise else: self.fail('Logout processResponseMsg should have failed.') @@ -200,8 +202,9 @@ class DefederationTestCase(unittest.TestCase): # The processNotificationMsg should fail but not abort. try: defederation.processNotificationMsg('nonLibertyQuery=1', lasso.httpMethodRedirect) - except lasso.SyntaxError: - pass + except lasso.Error, error: + if error[0] != lasso.PROFILE_ERROR_INVALID_QUERY: + raise else: self.fail('Defederation processNotificationMsg should have failed.') -- cgit