public void TestListLennyouseUserAsync() { ContextSeeders.Seed(); var bo = new LennyouseUserBusinessObject(); var resList = bo.ListAsync().Result; Assert.IsTrue(resList.Success && resList.Result.Count == 1); }
public void TestDeleteLennyouseUserAsync() { ContextSeeders.Seed(); var bo = new LennyouseUserBusinessObject(); var resList = bo.List(); var resDelete = bo.Delete(resList.Result.First().Id); resList = bo.ListAsync().Result; Assert.IsTrue(resDelete.Success && resList.Success); }
public void TestUpdateLennyouseUserAsync() { ContextSeeders.Seed(); var lubo = new LennyouseUserBusinessObject(); var resList = lubo.List(); var item = resList.Result.FirstOrDefault(); var _newLennyouseUser = new LennyouseUser(Guid.NewGuid()); item.PersonId = _newLennyouseUser.PersonId; var resUpdate = lubo.UpdateAsync(item).Result; resList = lubo.ListAsync().Result; Assert.IsTrue(resList.Success && resUpdate.Success && resList.Result.First().PersonId == _newLennyouseUser.PersonId); }