public void PageBar_ItemsPerPageClick_Test_1() { using (var driver = new ChromeDriver()) { /* Initialization */ var wait = new WebDriverWait(driver, TimeSpan.FromSeconds(60)); driver.Manage().Window.Maximize(); driver.Navigate().GoToUrl("https://tms.lionbridge.com/"); string projectTitle = "Qlik"; ProjectsPage testPage = new ProjectsPage(driver, projectTitle); testPage.ClickChosenProject(); ParticularProjectPage testProjectPage = new ParticularProjectPage(driver); testProjectPage.StatusClick(driver); StatusPage testStatusPage = new StatusPage(driver); testProjectPage.ProfileClick(driver); testProjectPage.ChangeItemsPerPageMin(driver); PageBar testPageBar = new PageBar(driver); /* Set of assertions */ Assert.IsTrue(testPageBar.IsParsingCorrect); Assert.AreEqual(0, testPageBar.ItemsPerPageOptionsContainerIsDisplayed); testPageBar.ItemsPerPageClick(driver); Assert.AreEqual(1, testPageBar.ItemsPerPageOptionsContainerIsDisplayed); } }
public void PageBar_ItemsPerPageClick_Test_3() { using (var driver = new ChromeDriver()) { /* Initialization */ var wait = new WebDriverWait(driver, TimeSpan.FromSeconds(60)); driver.Manage().Window.Maximize(); driver.Navigate().GoToUrl("https://lionbridge.com/"); PageBar testPageBar = new PageBar(driver); /* Set of assertions */ Assert.IsFalse(testPageBar.IsParsingCorrect); Assert.AreEqual(-1, testPageBar.ItemsPerPageOptionsContainerIsDisplayed); testPageBar.ItemsPerPageClick(driver); Assert.AreEqual(-1, testPageBar.ItemsPerPageOptionsContainerIsDisplayed); } }