CheckBoxvariable
Call this InteractorConstructor to initialize a checkbox Interactor.
The checkbox interactor can be used to interact with checkboxes on the page and
to assert on their state.
The checkbox is located by the text of its label.
Example
await CheckBox('Accept').check();
await CheckBox('Accept').is({ disabled: true });
await CheckBox({ id: 'accept', disabled: true }).exists();
Filters
title: string – Filter by titleid: string – Filter by idvisible: boolean – Filter by visibility. Defaults totrue. SeeisVisible.valid: boolean – Filter by whether the checkbox is valid.checked: boolean – Filter by whether the checkbox is checked.indeterminate: boolean - Filter by whether the checkbox has indeterminate state.disabled: boolean – Filter by whether the checkbox is disabled. Defaults tofalse.focused: boolean – Filter by whether the checkbox is focused. Seefocused.
Actions
click():Interaction– Click on the checkboxfocus():Interaction– Focus the checkboxblur():Interaction– Blur the checkboxcheck():Interaction– Check the checkbox if it is not checkeduncheck():Interaction– Uncheck the checkbox if it is checkedtoggle():Interaction– Toggle the checkbox