diff --git a/bindings/python/tests/profiles_tests.py b/bindings/python/tests/profiles_tests.py index 547c9e24..0ba1e56e 100755 --- a/bindings/python/tests/profiles_tests.py +++ b/bindings/python/tests/profiles_tests.py @@ -386,6 +386,21 @@ class LogoutTestCase(unittest.TestCase): else: self.fail('Logout processResponseMsg should have failed.') + def test05(self): + '''Test parsing of a logout request with more than one session index''' + content = ''' + me + coin + id1 + id2 + id3 + ''' + + node = lasso.Samlp2LogoutRequest.newFromXmlNode(content) + assert isinstance(node, lasso.Samlp2LogoutRequest) + assert node.sessionIndex == 'id1' + assert node.sessionIndexes == ('id1', 'id2', 'id3') + class DefederationTestCase(unittest.TestCase): def test01(self): """IDP initiated defederation; testing processNotificationMsg with non Liberty query.""" @@ -478,32 +493,15 @@ class AttributeAuthorityTestCase(unittest.TestCase): assert aq.response.assertion[0].attributeStatement[0].attribute[0] assert aq.response.assertion[0].attributeStatement[0].attribute[0].attributeValue[0] -class LogoutTestCase(unittest.TestCase): - def test01(self): - '''Test parsing of a logout request with more than one session index''' - content = ''' - me - coin - id1 - id2 - id3 - ''' - - node = lasso.Samlp2LogoutRequest.newFromXmlNode(content) - assert isinstance(node, lasso.Samlp2LogoutRequest) - assert node.sessionIndex == 'id1' - assert node.sessionIndexes == ('id1', 'id2', 'id3') - serverSuite = unittest.makeSuite(ServerTestCase, 'test') loginSuite = unittest.makeSuite(LoginTestCase, 'test') logoutSuite = unittest.makeSuite(LogoutTestCase, 'test') defederationSuite = unittest.makeSuite(DefederationTestCase, 'test') identitySuite = unittest.makeSuite(IdentityTestCase, 'test') attributeSuite = unittest.makeSuite(AttributeAuthorityTestCase, 'test') -logoutSuite = unittest.makeSuite(LogoutTestCase, 'test') allTests = unittest.TestSuite((serverSuite, loginSuite, logoutSuite, defederationSuite, - identitySuite, attributeSuite, logoutSuite)) + identitySuite, attributeSuite)) if __name__ == '__main__': sys.exit(not unittest.TextTestRunner(verbosity = 2).run(allTests).wasSuccessful())