Cannot swipe in iOS application web view

Hello guys,

Does anybody know how to perform swipe action in iOS application web view using appiumLibrary?

Thanks in advance.

@MSPower did you try switchContext before swipe? Add your code…

Thanks Aleksei for quick response.

I did not change any context. There is a button in application. When I perform click action, it opens web view page in application. So, I need to perform swipe from bottom to top action to see another content.

Can you explain or show a little example how to change content and perform swipe please?

@MSPower to switch driver into web view use:

public boolean switchToWebView() {
        sleep(5); //give time to load
        for(Object context : driver.getContextHandles()) {
            System.out.println("Context Name is " + context.toString());
            if(context.toString().contains("WEBVIEW")){
                driver.context(context.toString());
                return true;
            }
        }
        return false;
    }

how you make swipe?

Actually I am using robotframewok-appiumLibrary. The syntax is different.

swipe ${start_x} ${start_y} ${end_x} ${end_y}

@MSPower never used. can’t help with this… i am with Java-client for Appium

Another thing worth noting is that the Appium driver.swipe() command has been removed in the java-client 5.0