public void SelectByText(HtmlControl expandListButton, HtmlUnorderedList selectionList, string text) { expandListButton.Click(); selectionList.Find .ByContent <HtmlListItem>(text, ArtOfTest.WebAii.ObjectModel.FindContentType.InnerText) .Click(); }
/// <summary> /// Expand "Filter events by" /// </summary> public void ExpandFilteredEventsBy() { HtmlControl filterEventsByBtn = this.EM.Widgets.WidgetDesignerCalendarScreen.FilterEventsByButton; filterEventsByBtn.AssertIsPresent("Filter Events by button"); filterEventsByBtn.Click(); }
public void SelectByText(HtmlControl expandListButton, HtmlUnorderedList selectionList, string text) { expandListButton.Click(); selectionList.Find .ByContent<HtmlListItem>(text, ArtOfTest.WebAii.ObjectModel.FindContentType.InnerText) .Click(); }
public void SelectSubscription(string name) { var searchText = "//*[text()='match']"; searchText = searchText.Replace("match", name); var row = new HtmlControl(this, By.XPath(searchText)); row.Click(); }
public static void GoToItem(string pageNameString) { pageNameString = pageNameString.Replace('_', ' '); HtmlControl barElements = TTFDriver.myManager.ActiveBrowser.Find.ByAttributes <HtmlDiv>("class=topbar"). Find.ByContent <HtmlControl>(pageNameString); barElements.Click(); }
public void ChooseModule(HtmlControl htmlElement) { htmlElement.Click(); }
public void TC06_VerifyDeleteRow() { NavigateToMetersPage(); int initialRowCount = Page.MetersTabPage.MetersTabGrid.Rows.Count; Thread.Sleep(2000); IList<Element> buttons = Page.MetersTabPage.MetersTabGrid.Rows.LastOrDefault().GetButtons(); DialogHandler.ClickonOKButton(); HtmlControl deleteButton = new HtmlControl(buttons[1]); deleteButton.Click(); Thread.Sleep(2000); if (Page.MetersTabPage.MetersTabGrid.Rows.Count == initialRowCount) { Assert.Fail("Row deletion did not happen"); } if (null != Page.ContactsTabPage.ErrorMsg) { if (!Page.ContactsTabPage.ErrorMsg.BaseElement.InnerText .Equals(@"Contact deleted Successfully")) { Assert.Fail("Incorrect error message is displayed,Expected: Contact deleted Successfully" + " but Actual:" + Page.ContactsTabPage.ErrorMsg.BaseElement.InnerText); } } else { Assert.Fail("Error message is not displayed"); } //TODO: Add DB validation after manual test cases are updated }
public void TC05_VerifyUpdateCancel() { NavigateToMetersPage(); Thread.Sleep(2000); IList<Element> buttons = Page.MetersTabPage.MetersTabGrid.Rows.FirstOrDefault().GetButtons(); HtmlControl updateButton = new HtmlControl(buttons.LastOrDefault()); updateButton.Click(); Page.MetersTabPage.MeterName.Text = ""; KeyBoardSimulator.KeyPress(Keys.Tab); Page.MetersTabPage.MeterName.Focus(); Page.MetersTabPage.MeterName.ExtendedMouseClick(); KeyBoardSimulator.SetText("TrialText"); Page.MetersTabPage.EditMeterCancelButton.Click(); Assert.False(Page.MetersTabPage.MetersTabGrid.Rows.FirstOrDefault().InnerText.Contains("TrialText")); }