public HttpResponseMessage Get(string key) { PeopleRepository p = new PeopleRepository(); var result = p.SearchPeople(key); HttpResponseMessage response = Request.CreateResponse(HttpStatusCode.OK, result); return response; }
public void Returns_SpecificRows() { // Arrange PeopleRepository p = new PeopleRepository(); // Act List<People_Search.UserDetail>actual = p.SearchPeople("Jay"); // Assert Microsoft.VisualStudio.TestTools.UnitTesting.Assert.AreEqual(1, actual.Count); }
public PeopleController(PeopleRepository repository) { this.repository = repository; }
public PeopleController() { this.repository = new PeopleRepository(); }