Overview
- This toturial only explains how to connect with Appium on Android device.
- It needs to enable the "Developer Options" on real Android phone and provide capabilities to connect with the Appium.
Enable Settings On Android
ENABLE Developer Options on Android
- Each brands of phone have its own method to enable developer options, check it here.
- Enable USB debugging
- Developer Options > Debugging > USB debugging > Enable it
- Stay awake
- Developer Options > Stay awake > Enable it
Set Up Mobile Capabilities
Mobile Capabilities With JSON Format
# JSON representation
{
"appium:platformName": "Android",
"appium:deviceName": "Pixel 4",
"appium:udid": "9924**AZ006LY",
"appium:platformVersion": "13",
"appium:appPackage": "",
"appium:appActivity": "",
"appium:noReset": "false",
"appium:fullReset": "false",
"appium:newCommandTimeout": "0",
"appium:autoGrantPermissions": "true"
}
- EXPLANATION
Parameters | Descriptions | Notes |
---|---|---|
"appium:platformName" | OS type of device (e.g. Android, iOS) | - |
"appium:platformVersion" | System Version of device (e.g. 13, 14, 10.0) | - |
"appium:deviceName" | Model name of device find in "System" > "About Phone" > "Model" | - |
"appium:udid" | Serial number of device find in "System" > "About Phone" > "Model" > "Serial number". | - |
"appium:realDeviceLogger" | saved path of deviceconsole tool, it can get log via this | - |
"appium:app" | iOS only path of APP, it will same as bundleId if doesn't set. | - |
"appium:bundleId" | iOS only bundleId of APP. | - |
"appium:appPackage" | Android only package name of APP | - |
"appium:appActivity" | Android only path of APP | - |
"appium:newCommandTimeout" | Maximum time interval between 2 commands, if interval reaches out, session will close. Set to "0" if interval is no limit. | - |
"appium:automationName" | Appium driver version Under Android 4.2 is Selendroid, Above Android 4.2 or iOS is Appium. | - |
"appium:noReset" | Boolean, TRUE of FASLE set to TRUE, the app data will NOT be cleared before this session starts. | - |
"appium:fullReset" | Boolean, TRUE of FASLE set to TRUE, the app will be uninstalled and all data will be cleared. | - |
"appium:autoGrantPermissions" | Boolean, TRUE of FASLE | - |
FAQ
- What if Unicode IME doesn't exists on your phone
- If there isn't "Unicode IME" option exists on your keyboard list, try run Appium inspector once, it will install it automatically.