0001-Revert-idp_oidc-add-api-access-and-profile-71820-718.patch
src/authentic2_idp_oidc/manager/forms.py | ||
---|---|---|
38 | 38 |
'authorization_mode', |
39 | 39 |
'authorization_flow', |
40 | 40 |
'home_url', |
41 |
'has_api_access', |
|
42 |
'activate_user_profiles', |
|
43 | 41 |
'colour', |
44 | 42 |
'logo', |
45 | 43 |
] |
tests/idp_oidc/test_manager.py | ||
---|---|---|
37 | 37 |
form = resp.form |
38 | 38 |
form['name'] = 'Test' |
39 | 39 |
form['redirect_uris'] = 'http://example.com' |
40 |
form['has_api_access'] = True |
|
41 |
form['activate_user_profiles'] = True |
|
42 | 40 |
resp = form.submit() |
43 | 41 | |
44 | 42 |
assert OIDCClient.objects.count() == 1 |
45 | 43 |
assert OIDCClaim.objects.count() == len(oidc_app_settings.DEFAULT_MAPPINGS) |
46 | 44 |
oidc_client = OIDCClient.objects.get() |
47 |
assert oidc_client.has_api_access is True |
|
48 |
assert oidc_client.activate_user_profiles is True |
|
49 | 45 |
assert resp.location == f'/manage/services/{oidc_client.pk}/' |
50 | 46 |
resp = resp.follow() |
51 | 47 |
assert "Settings" in resp.text |
52 |
- |