Appium Inspector for Real Android Devices — Setup Guide

Deniz Sivas
Apr 18, 2024

--

Photo by Denny Müller on Unsplash

It begins with the correct capability settings. So, let’s start with finding the right UDID and package name.

adb devices

It gives the UDID of the Android device.

Now, open up the app you would like to inspect and keep it open in the phone. Go to your terminal and run the below command.

adb shell dumpsys window | grep -E 'mCurrentFocus'

I opened up Youtube app and ran the command, the output was like the below one.

The yellow highlighted part is your app activity name.

How to enter this info to your capability set

{
"platformName": "Android",
"appium:deviceName": "TestPhone",
"appium:udid": "228XXXXXX",
"appium:appActivity": "com.google.android.apps.youtube.app.watchwhile.InternalMainActivity",
"appium:noReset": "true",
"appium:wdaLocalPort": "8101",
"appium:automationName": "UiAutomator2"
}

--

--

Deniz Sivas

Software tester by profession, software developer by passion