0001-authenticators-keep-correct-name-in-login_block-6710.patch
src/authentic2/utils/misc.py | ||
---|---|---|
229 | 229 |
extra_css_class = response.context_data.get('block-extra-css-class', '') |
230 | 230 |
return { |
231 | 231 |
'id': authenticator.get_identifier(), |
232 |
'name': authenticator.name, |
|
232 |
'name': authenticator._meta.verbose_name if hasattr(authenticator, '_meta') else authenticator.name,
|
|
233 | 233 |
'content': content, |
234 | 234 |
'response': response, |
235 | 235 |
'status_code': status_code, |
tests/test_auth_saml.py | ||
---|---|---|
50 | 50 |
response = app.get('/login/') |
51 | 51 |
assert response.pyquery('button[name="login-saml-idp1"]') |
52 | 52 |
assert not response.pyquery('button[name="login-saml-1"]') |
53 |
assert 'SAML' in response.text |
|
53 | 54 | |
54 | 55 |
SAMLAuthenticator.objects.create(enabled=True, metadata='meta1.xml', slug='idp2') |
55 | 56 |
response = app.get('/login/') |
56 |
- |