public void tapElement(AppiumWebElement element) { TouchActions actions = new TouchActions(driver); actions.SingleTap(element); actions.Perform(); }
protected void Tap(IWebElement element) { WaitForElement(element); TouchActions action = new TouchActions(DriverFactory.INSTANCE); action.SingleTap(element); action.Perform(); }
protected void Tap(IWebElement element) { //waitForElement(element); //TouchActions action = new TouchActions(driver); //action.singleTap(element); //action.perform(); WaitForElement(element); //IWebElement iElement = driver.FindElement(element); TouchActions action = new TouchActions(DriverFactory.GetDriver()); action.SingleTap(element); action.Perform(); }
public void ShouldTouch() { //Dictionary<String, String> mobileEmulation = new Dictionary<String, String>(); //mobileEmulation.Add("deviceName", "Nexus 5"); ChromeOptions chromeCapabilities = new ChromeOptions(); chromeCapabilities.EnableMobileEmulation("Google Nexus 5"); var driver = new TouchCapableChromeDriver(); driver.Navigate().GoToUrl("https://en.wikipedia.org/wiki/Main_Page"); var element = driver.FindElement(By.Id("searchInput")); var touchActions = new TouchActions(driver); touchActions.SingleTap(element) .Perform(); driver.Quit(); }