Skip to main content
Version: 1.x

Function: feSelectListItem()

feSelectListItem(page, listId, itemIndex, selected): Promise<void>

Defined in: src/fe/fe-list-helpers.ts:324

Selects or deselects a list item at the specified index.

Parameters

page

FEListPage

Playwright Page (or compatible subset).

listId

string

The UI5 control ID of the list.

itemIndex

number

Zero-based index of the item to select.

selected

boolean

true to select, false to deselect.

Returns

Promise<void>

Remarks

Calls setSelected(selected) on the list item and fires selectionChange on the list.

Throws

ControlError with ERR_CONTROL_AGGREGATION if the index is invalid.

Example

await feSelectListItem(page, 'myApp--productList', 0, true);