0001-authenticators-hide-empty-kebab-menu-for-password-au.patch
src/authentic2/apps/authenticators/templates/authentic2/authenticators/authenticator_detail.html | ||
---|---|---|
4 | 4 |
{% block appbar %} |
5 | 5 |
{{ block.super }} |
6 | 6 |
<span class="actions"> |
7 |
{% if not object.internal %} |
|
7 | 8 |
<a class="extra-actions-menu-opener"></a> |
9 |
{% endif %} |
|
8 | 10 | |
9 | 11 |
<a href="{% url 'a2-manager-authenticator-toggle' pk=object.pk %}">{{ object.enabled|yesno:_("Disable,Enable") }}</a> |
10 | 12 |
<a href="{% url 'a2-manager-authenticator-edit' pk=object.pk %}">{% trans "Edit" %}</a> |
tests/test_manager_authenticators.py | ||
---|---|---|
43 | 43 |
assert 'Click "Edit" to change configuration.' in resp.text |
44 | 44 |
# cannot delete password authenticator |
45 | 45 |
assert 'Delete' not in resp.text |
46 |
assert 'extra-actions-menu-opener' not in resp.text |
|
46 | 47 |
app.get('/manage/authenticators/1/delete/', status=403) |
47 | 48 | |
48 | 49 |
resp = resp.click('Edit') |
49 |
- |