public void AddFacultative() { RestoreDate(); var FacultativeRepository = new FacultativeRepository(mockContext.Object); Facultative Facultative = new Facultative(); FacultativeRepository.Add(Facultative); Assert.IsNotNull(_Facultatives.Where(s => Facultative.Id == s.Id).FirstOrDefault()); Assert.AreEqual(FacultativeRepository.Get(Facultative.Id).Id, Facultative.Id); }
public void GetFacultativeById() { RestoreDate(); var FacultativeRepository = new FacultativeRepository(mockContext.Object); Facultative Facultative = new Facultative(); FacultativeRepository.Add(Facultative); Assert.IsNotNull(_Facultatives.FirstOrDefault()); Assert.IsNotNull(FacultativeRepository.Get(Facultative.Id)); }