Skip to main content

UI ELEMENTS

Checkboxes & Radio Buttons

Single checkboxes, grouped checkboxes with an indeterminate parent, radio groups, and toggle switches.

How to use this page

Goal: Select and deselect each control, then confirm the underlying state (checked, indeterminate, or value) updates correctly.

Challenge: The 'Select all' checkbox has an indeterminate state when only some items are checked. Most locator libraries don't expose that as a simple attribute check.

Single Checkbox

A standalone checkbox with a label.

Checkbox Group

A 'select all' checkbox controlling three child checkboxes, with indeterminate state when only some are checked.

Radio Group

A mutually exclusive set of options.

Preferred testing approach

Toggle Switch

An on/off switch exposing aria-checked.

Need this tested professionally?

Testing complex form state on a production product? We run test automation services for complex form state and accessibility testing services that check grouped inputs are announced correctly. Get in touch to discuss your project.