public void AssertIndexPage() { PageContentElement = AppElement.FindElement(By.CssSelector("div.pageContent")); PlanningPokerContainerElement = PageContentElement.FindElement(By.CssSelector("div.planningPokerContainer")); ContainerElement = PlanningPokerContainerElement.FindElement(By.XPath("./div[@class='container']")); CreateTeamForm = ContainerElement.FindElement(By.CssSelector("form[name='createTeam']")); JoinTeamForm = ContainerElement.FindElement(By.CssSelector("form[name='joinTeam']")); }
public void Disconnect() { var navbarPlanningPokerElement = PlanningPokerContainerElement.FindElement(By.Id("navbarPlanningPoker")); var disconnectElement = navbarPlanningPokerElement.FindElement(By.TagName("a")); Assert.AreEqual("Disconnect", disconnectElement.Text); disconnectElement.Click(); CreateTeamForm = ContainerElement.FindElement(By.CssSelector("form[name='createTeam']")); Assert.AreEqual($"{Server.Uri}Index", Browser.Url); }