public void AddContest() { Login(); HomePageObjects homeObj = new HomePageObjects(); homeObj.ShowDropdownList(); ContestListPageObjects contestListObj = homeObj.GoToContestListPage(); ContestAddPageObject contestAddPageObj = contestListObj.AddContest(); contestListObj = contestAddPageObj.CreateContest(ExcelLib.ReadData(1, "ContestName"), ExcelLib.ReadData(1, "ContestDate").Remove(10), ExcelLib.ReadData(1, "ContestDescription")); contestListObj = contestListObj.SearchContest(ExcelLib.ReadData(1, "ContestName")); Assert.AreEqual(contestListObj.GetNameOfContest(), ExcelLib.ReadData(1, "ContestName")); Assert.AreEqual(contestListObj.GetDateOfContest(), ExcelLib.ReadData(1, "ContestDate").Remove(10)); Assert.AreEqual(contestListObj.GetDescriptionOfContest(), ExcelLib.ReadData(1, "ContestDescription")); }
public void DeleteContest() { Login(); HomePageObjects homeObj = new HomePageObjects(); homeObj.ShowDropdownList(); ContestListPageObjects contestListObj = homeObj.GoToContestListPage(); contestListObj = contestListObj.SearchContest(ExcelLib.ReadData(1, "ContestName")); ContestConfirmDeletePageObjects contestConfirmDelObj = contestListObj.DeleteContest(); contestListObj = contestConfirmDelObj.ConfirmDelete(); contestListObj = contestListObj.SearchContest(ExcelLib.ReadData(1, "ContestName")); Assert.AreEqual(contestListObj.GetNameOfContest(), ""); Assert.AreEqual(contestListObj.GetDateOfContest(), ""); Assert.AreEqual(contestListObj.GetDescriptionOfContest(), ""); }