public void GetAllEmptyClient() { var getAll = new List <Client>(); var clientExpected = new List <Client>(); using (var db = new EntitesContext()) { ClearTable.Clients(db); clientDAO = new DbClientDAO(db); getAll = clientDAO.GetAll(); } CollectionAssert.AreEqual(getAll, clientExpected); }
public void GetAllClient() { List <Client> getAll; var clients = CreateListEntities.Clients(); using (var db = new EntitesContext()) { ClearTable.Clients(db); clientDAO = new DbClientDAO(db); foreach (var cl in clients) { clientDAO.Add(cl); } getAll = clientDAO.GetAll(); } CollectionAssert.AreEqual(getAll, clients); }
public List <Client> GetAll() => clientDAO.GetAll();