Skip to main content

ElementListVisible

Description

Matching command to ElementListSelect. Will make an element on a list visible.

info

Note: This command will work only on instrumented applications

Parameters

NameValueDescription
List locatorStringA String identifier of List locator
Element locatorStringA String identifier of Element locator
IndexIntegerElement Index

Usage

This is actually elementListSelect command with click parameter of false.

Example

Consider the EriBank Application,

Step 1: Login to the EriBank application.

Step 2: Click the Make Payment button.

Step 3: Click Select button.

In Automation mode open Open the Object Spy.

Now we need to find the list locator identifier.

Click the parent of the list element and note down the list locator identifier which is in this case "accessibility=conutryView".

Now we need to find the element identifier,

Click any element in the list and note down the Element identifier which is text=Greece.

Once this is done the following code cane be used to select the Element in the list locator.

info

Replace <server> with the appropriate URL.

ElementListVisible

DesiredCapabilities dc = new DesiredCapabilities();
driver = new AndroidDriver(new URL("<server>"), dc);
seetest = new SeeTestClient(driver);
dc.setCapability(MobileCapabilityType.UDID, "deviceid");

...
...

seetest.elementListVisible("accessibilityLabel=conutryView","text=Greece", 0);