Search code examples
javascriptappiumwebdriver-ioappium-androidandroid-uiautomator

Appium & UiAutomator2 automate already opened app


I would appreciate if someone could tell me if it is possible to run a test with the UiAutomator2 driver from an already opened android application. If yes, could you please enlighten me on how to do so, what capablilities/options should I use.

Info : I am using javascript + webdriverio to write my tests.

Thanks in advance, Volck


Solution

  • The way to start a session using the UiAutomator2 driver is to include the automationName capability in your new session request, with the value UiAutomator2. Of course, you must also include appropriate platformName (=Android), platformVersion, deviceName, and app capabilities, at a minimum.

    Check here