Connecting Appium Desktop to an android emulator to inspect the app - dn0000001/test-automation GitHub Wiki
Prerequisites
- You have docker-android up and running. (See Setting up docker with android emulator & appium)
Instructions for Appium Desktop
- Launch appium-desktop
- Go to File > New Session Window (Ctrl + N)
- It may take a few seconds for the window to load
- Click Custom Server
- The defaults will connect to the docker-android container defaults
- Click Desired Capabilities
- Click Edit Raw JSON
- Paste in your capabilites and click Save
- Click Start Session
- You should be the app launch in the docker container. (This may take some time.)
- You can then inspect the app
Note: Appium Desktop has been deprecated instead use Appium Inspector.
Capabilities for Calculator
{
"platformName": "Android",
"platformVersion": "8.1",
"deviceName": "Samsung Galaxy S6",
"appPackage": "com.android.calculator2",
"appActivity": "com.android.calculator2.Calculator"
}
How to find the appPackage & appActivity properties for your app
- Install Package Name Viewer from https://apkpure.com/package-name-viewer-2-0/com.csdroid.pkg inside the docker-android container
- Launch Package Name Viewer and use it to find your app and display the appPackage & appActivity.
Notes
- It will be necessary to allow installs from untrusted sources.
- It is also possible to get the appPackage & appActivity from Appium Desktop