def test_saml_bad_soap(self): """ raise_if_saml_failed should raise an error if HTML is given. """ with self.assertRaises(XMLSyntaxError): raise_if_saml_failed(SAML_AUTHNFAILED_HTML)
def test_saml_success(self): """ raise_if_saml_failed should not raise an error on success. """ raise_if_saml_failed(SAML_SUCCESS)
def test_saml_authnfailed(self): """ raise_if_saml_failed should raise an error if AuthNfailed. """ with self.assertRaises(AuthnFailed): raise_if_saml_failed(SAML_AUTHNFAILED)