Inspect Tools

Inspect tool is used to locate the values of Mobile Elements for the application to perform action on it.

Here we are going to discuss how to find Mobile Element locator values using Appium Inspector.

Appium Inspector

Follow the below steps to inspect the Mobile Elements in appium inspector

Let us divide into three categories

  • Enter the desired capabilities in JSON representation.
  • Save the desired capabilities for later use.
  • Start Session to inspect the mobile elements .

Enter the desired capabilities in JSON representation

1. Launch the Appium Server from installed applications in you PC

2. Click on”Star Server” on Appium Server

Appium Server

3. Click on “Start Inspector session”

Start Appium inspector

4. Click on “Edit RAW JSON” in JSON Representation.

Click on Edit Button

5. Enter the Desired capabilities in JSON Representation such as "appPackage" ,"appActivity","platformName","deviceName" ,"udid"(device id) in parentheses "{ }".

"appPackage"  : "com.skill2lead.appiumdemo",
"appActivity" : "com.skill2lead.appiumdemo.MainActivity",
"platformName": "Android",
"deviceName"  : "Pixel",
"udid"        : "7HAF9XXX"

6. Click on Save button

Enter Data in JSON

7. Now entered desired capabilities in JSON representation will show the data in the left side of “Desired Capabilities” section.

Show Data

Save the desired capabilities for later use.

1. Click on “Save As” in JSON representation.

Save Data

2. Enter the Name and Click on Save

Enter Name

3. Now entered desired capabilities data will show in the “Saved Capabilities” section on the left side.

4. When we save the data then count will increase and we can see the count at side of “Save Capabilities” as “Save Capabilities Sets count”.

Show Data in Capabilities section

Start Session to inspect the mobile elements.

1. Click on “Start Session” under JSON Representation.

Start Session

2. Now it will launch the app which we have given data in desired capabilities and we can see the mirror image of the app on the left side.

3. Now , Click on Select Elements button.

4. Place the mouse pointer on the required element to inspect.

Inspect Element

5. We can see the data of the selected element on the right side.

Appium Inspector