public async Task getPersonByFirstName() { var context = new Entities(); Repository.PersonRepository.Person person = new Repository.PersonRepository.Person(context); var test = await person.GetPersonByFirstNameAsync("John"); Assert.AreEqual("John", test.FirstName); }
public async Task getListOfBusinesses() { var context = new Entities(); Repository.PersonRepository.Person person = new Repository.PersonRepository.Person(context); var test = await person.GetPersonByLastNameAsync("Smith"); Assert.AreEqual("Smith", test.LastName); }
private void personBusinnessEntityID() { Repository.PersonRepository.Person person; using (var context = new Entities()) { person = new Repository.PersonRepository.Person(context); this.businessEntityPersonID = person.GetPersonBusinessEntityID(); this.businessEntityContactID = person.GetBusinessEntityID(); } this.businessEntityPersonID++; this.businessEntityContactID++; }
public void getListOfPerson() { var context = new Entities(); Repository.PersonRepository.Person person = new Repository.PersonRepository.Person(context); var items = person.GetPersons(); //returns object of AdventureWorks.Model.Person and prints values in model. foreach (var item in items) { Console.WriteLine(item.FirstName); } }