MCPcopy Create free account
hub / github.com/react-component/select / selectItem

Function selectItem

tests/utils/common.ts:27–33  ·  view source on GitHub ↗
(wrapper: any, index: number = 0)

Source from the content-addressed store, hash-verified

25}
26
27export function selectItem(wrapper: any, index: number = 0) {
28 if (wrapper instanceof HTMLElement) {
29 fireEvent.click(wrapper.querySelectorAll('.rc-select-item-option-content')[index]);
30 return;
31 }
32 wrapper.find('div.rc-select-item-option-content').at(index).simulate('click');
33}
34
35export function findSelection(wrapper: any, index: number = 0) {
36 if (wrapper instanceof HTMLElement) {

Callers 5

Combobox.test.tsxFile · 0.90
Select.test.tsxFile · 0.90
Multiple.test.tsxFile · 0.90
removeSelectedTestFunction · 0.90
dynamicChildrenTestFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…