[TestCase("pinkfloyd", "password")] //enters valid username and password public void TestProfilePageTitleAndFooter(string user, string password) { //calls helper method InitLoginPage InitLoginPage(user, password, null, null, null); Thread.Sleep(2000); //creates instance of NavigationControl object Navigationcontrol navControl = new Navigationcontrol(driver); //verifies navigation links VerifyNavigationControl(navControl); //clicks on profile link navControl.GotoProfile(); Thread.Sleep(2000); //creates new Explore page object ProfilepageTitleandFooter profilepageTitle = new ProfilepageTitleandFooter(driver); Thread.Sleep(2000); //explore title var expected = "PinkFloyd's profile - BC Yips!"; var actual = driver.Title; Assert.AreEqual(expected, actual, "title does not match"); //verifies footer on home page expected = "© 2020 - Bellevue College"; actual = profilepageTitle.FooterBC.Text; Assert.AreEqual(expected, actual, "Footer does not match"); }
[TestCase("pinkfloyd", "password")] //enters valid username and password public void TestUserProfileAndYippersHeader(string user, string password) { //calls helper method InitLoginPage InitLoginPage(user, password, null, null, null); Thread.Sleep(2000); //creates instance of NavigationControl object Navigationcontrol navControl = new Navigationcontrol(driver); //verifies navigation links VerifyNavigationControl(navControl); //clicks on profile link navControl.GotoProfile(); Thread.Sleep(2000); //creates new Explore page object ProfilepageTitleandFooter profilepageTitle = new ProfilepageTitleandFooter(driver); Thread.Sleep(2000); //checks user profile and yippers header profilepageTitle.VerifyUserProfileAndYippersHeader("PinkFloyd"); }