Revert user deletion job

This commit is contained in:
richard-dds
2019-10-14 16:51:19 -04:00
parent 73a459ea28
commit 1bce0a1f01
10 changed files with 79 additions and 131 deletions

View File

@@ -35,15 +35,16 @@ def test_update_env_role():
assert env_role.role == new_role
def test_update_env_role_no_access(session):
def test_update_env_role_no_access():
env_role = EnvironmentRoleFactory.create(role=CSPRole.BASIC_ACCESS.value)
assert Environments.update_env_role(
env_role.environment, env_role.application_role, None
)
session.refresh(env_role)
assert env_role.status == EnvironmentRole.Status.PENDING_DELETE
assert not EnvironmentRoles.get(
env_role.application_role.id, env_role.environment.id
)
def test_update_env_role_no_change():