public void CanCreateNewUser() { var user = new User() .SetDataToCreate(Name, Email, this.services, UserStatusEnum.Active) .Save(this.repository); Assert.IsFalse(string.IsNullOrEmpty(user.Id)); }
public void CanGetAnUser() { new User() .SetDataToCreate(Name, Email, this.services, UserStatusEnum.Active) .Save(this.repository); var user = new User() .Get(new UserFilter().SetEmail(Email), this.repository); Assert.IsNotNull(user); Assert.IsFalse(string.IsNullOrEmpty(user.Id)); }
private void ProcessUser(User user) { if (user == null) return; if(user.ServicesList == null || !user.ServicesList.Any()) return; foreach (var service in user.ServicesList) this.ProcessService(service); }