public void DeleteSeatsFromCart() { GoToUrl(ConfigurationManager.AppSettings["SiteUrl"] + "Account/Cart"); var deleteButtons = FindElementsByXpath("//*[contains(@onclick, 'DeleteSeatFromCart')]"); Thread.Sleep(150); deleteButtons.ToList().ForEach(x => { x.Click(); CustomConditionals.WaitForNotisfaction(Driver); }); }
public void LockSeatOfTestEvent() { //find event by title GoToUrl(ConfigurationManager.AppSettings["SiteUrl"]); var filterOption = FindByXPath("//select[@id='filterList']//option[contains(@value,'Title')]"); filterOption.Click(); CustomConditionals.SendedToField(Driver, By.Id("filterInput"), "test event"); FindByXPath("//*[contains(@value, 'Search')]").Click(); //lock a seat var selectEvent = FindByXPath("//div[contains(text(),'test event')]/parent::a"); GoToUrl(selectEvent.GetAttribute("href")); var firstSeat = FindByXPath("//*[contains(@class,'seat-available') and contains(@class, 'seat-seatmap')]"); firstSeat.Click(); CustomConditionals.WaitForNotisfaction(Driver); }