public void HasAdminPermissionTest() { //Arrange. repo.Setup(r => r.Get(admin.UserName)).Returns(admin); //Act. authService.SetSession(admin.UserName); //Assert. authService.AuthenticateAdmin(); repo.VerifyAll(); }