Variable SelectConst

Select: any = SelectInteractor

Call this InteractorConstructor to initialize an Interactor for select boxes. The select interactor can be used to interact with select boxes and to assert on their state.

For interacting with multiple select boxes, see MultiSelect.

The select box is located by the text of its label.

await Select('Language').select('English');
await Select('Language').has({ value: 'English' });
  • title: string – Filter by title
  • id: string – Filter by id
  • valid: boolean – Filter by whether the select box is valid.
  • value: string – Filter by the text of the selected option.
  • visible: boolean – Filter by visibility. Defaults to true. See isVisible.
  • disabled: boolean – Filter by whether the select box is disabled. Defaults to false.
  • focused: boolean – Filter by whether the select box is focused. See focused.
  • click(): Interaction – Click on the select box
  • focus(): Interaction – Move focus to the select box
  • blur(): Interaction – Move focus away from the select box
  • choose(text: string): Interaction – Choose the option with the given text from the select box.