public void SaveSurveyTest() { ParkWeatherSqlDal dal = new ParkWeatherSqlDal(connectionString); Survey survey = new Survey() { ParkCode = "ABC", EmailAddress = "", State = "", ActivityLevel = "" }; bool tableAffected = dal.SaveSurvey(survey); Assert.AreEqual(true, tableAffected); }
public void MostPopParkBySurveyTest() { ParkWeatherSqlDal dal = new ParkWeatherSqlDal(connectionString); Survey survey = new Survey() { ParkCode = "ABC", EmailAddress = "", State = "", ActivityLevel = "" }; for (int i = 0; i < numRowsInSurveyTable + 1; i++) { dal.SaveSurvey(survey); } Park testPark = dal.MostPopularBySurvey(); Assert.AreEqual("ABC", testPark.ParkCode); }