Ejemplo n.º 1
0
        public void TestRoleCannotBeDeletedWhilePopulatedIfForbidden()
        {
            var userId = AddUserFred();

            _provider.CreateRole("Programmer");
            _provider.AddUserToRoles(userId, new[] { "Programmer" });
            _provider.DeleteRole("Programmer", true);
        }
Ejemplo n.º 2
0
 public override bool DeleteRole(string roleName, bool throwOnPopulatedRole)
 {
     return(RoleProvider.DeleteRole(roleName, throwOnPopulatedRole));
 }
 public void TestRoleCannotBeDeletedWhilePopulatedIfForbidden()
 {
     _provider.CreateRole("Programmer");
     _provider.AddUserToRoles("admin", new[] { "Programmer" });
     _provider.DeleteRole("Programmer", true);
 }