make sure tests all populate the platform admin field

it's always returned by the API
This commit is contained in:
Leo Hemsted
2019-06-14 15:14:00 +01:00
parent c724f84c23
commit d752a6335f
2 changed files with 10 additions and 1 deletions

View File

@@ -77,6 +77,7 @@ class HeaderNavigation(Navigation):
'user_profile_mobile_number_confirm',
'user_profile_name',
'user_profile_password',
'user_profile_disable_platform_admin_view',
},
'platform-admin': {
'add_organisation',
@@ -571,6 +572,7 @@ class MainNavigation(Navigation):
'user_profile_mobile_number_confirm',
'user_profile_name',
'user_profile_password',
'user_profile_disable_platform_admin_view',
'using_notify',
'verify',
'verify_email',
@@ -838,6 +840,7 @@ class CaseworkNavigation(Navigation):
'user_profile_mobile_number_confirm',
'user_profile_name',
'user_profile_password',
'user_profile_disable_platform_admin_view',
'using_notify',
'verify',
'verify_email',
@@ -1106,6 +1109,7 @@ class OrgNavigation(Navigation):
'user_profile_mobile_number_confirm',
'user_profile_name',
'user_profile_password',
'user_profile_disable_platform_admin_view',
'using_notify',
'verify',
'verify_email',

View File

@@ -1431,6 +1431,7 @@ def api_user_locked(fake_uuid):
'auth_type': 'sms_auth',
'organisations': [],
'current_session_id': None,
'platform_admin': False,
}
return user_data
@@ -1449,6 +1450,7 @@ def api_user_request_password_reset(fake_uuid):
'auth_type': 'sms_auth',
'organisations': [],
'current_session_id': None,
'platform_admin': False,
}
return user_data
@@ -1467,6 +1469,7 @@ def api_user_changed_password(fake_uuid):
'password_changed_at': str(datetime.utcnow() + timedelta(minutes=1)),
'organisations': [],
'current_session_id': None,
'platform_admin': False,
}
return user_data
@@ -2172,7 +2175,9 @@ def mock_get_users_by_service(mocker):
'email_address': 'notify@digital.cabinet-office.gov.uk',
'auth_type': 'sms_auth',
'failed_login_count': 0,
'organisations': []}]
'organisations': [],
'platform_admin': False,
}]
return [data[0]]
# You shouldnt be calling the user API client directly, so its the