# Button and icon button

**Test family:** `BTN`

- **BTN-001** Name states the action; icon-only buttons have an accessible name and recognizable tooltip where helpful.
- **BTN-002** Enter/Space activates once; disabled state cannot receive or trigger the action.
- **BTN-003** Loading state preserves dimensions, communicates progress, and prevents unintended duplicate activation.
- **BTN-004** Rapid click, double click, keyboard repeat, retry, and network replay do not duplicate non-idempotent effects.
- **BTN-005** Primary/destructive/secondary visual hierarchy matches consequence.
- **BTN-006** Action applies to the visibly scoped object, especially in cards, rows, bulk selections, and menus.
- **BTN-007** Error returns focus and preserves recoverable input; success moves focus/announces state appropriately.
- **BTN-008** Small/narrow/touch layouts retain a usable target and do not hide the only completion action.

## Comprehensive per-item coverage

- **BTN-009** Verify absent, loading, initial, default, selected/open, disabled, read-only, invalid, pending, success, and error states are visually and programmatically distinct.
- **BTN-010** Activate with pointer, touch, keyboard, switch control, voice command, and automation APIs; produce one equivalent action per intentional activation.
- **BTN-011** Verify the accessible role, name, description, value/state, relationships, and focus behavior match the visible control.
- **BTN-012** Use adjacent labels or record names containing ASCII emoticons, emoji, kaomoji, RTL text, combining marks, and very long strings; render them safely without breaking activation.
- **BTN-013** Use labels with `&`, `<`, `>`, quotes, slashes, template delimiters, and CSV-formula prefixes; render text inertly in UI, logs, notifications, and exports.
- **BTN-014** Traverse with Tab, Shift+Tab, arrows, Home/End, Enter, Space, Escape, and platform conventions; never trap or unexpectedly move focus.
- **BTN-015** Double-click, double-tap, press Enter repeatedly, and retry after a slow response; prevent duplicate actions and expose truthful progress.
- **BTN-016** Change state while the control is focused, open, offscreen, or being announced; avoid stale accessible state and lost focus.
- **BTN-017** Attempt activation when hidden, disabled, read-only, unauthorized, expired, or stale through both UI and direct requests; enforce the server rule.
- **BTN-018** Interrupt the action with navigation, refresh, offline transition, timeout, server error, and session expiry; recover or roll back coherently.
- **BTN-019** Use two sessions to change the same state simultaneously; define conflict, ordering, and final-state behavior.
- **BTN-020** Reload, revisit, deep-link, back/forward, duplicate the tab, and restore a crashed session; preserve or reset state according to product intent.
- **BTN-021** Test the control inside forms, dialogs, menus, tables, repeated rows, nested landmarks, and virtualized content; keep names and targets unique.
- **BTN-022** Test narrow and wide screens, portrait/landscape, 200% text, 400% reflow, high contrast, reduced motion, and touch target sizing.
- **BTN-023** Translate and lengthen labels, use RTL layout, and change locale while state exists; preserve meaning, order, and action target.
- **BTN-024** Exercise 1, many, and very many repeated controls; keep rendering, interaction, and announcements responsive.
- **BTN-025** Verify analytics, audit events, notifications, and downstream requests occur once, contain the intended target, and omit unrelated sensitive data.
- **BTN-026** Change permissions or ownership between render and activation; reauthorize at commit time and explain rejection without leaking hidden data.
- **BTN-027** Undo, cancel, dismiss, reset, or restore where promised; make irreversible transitions explicit and require an appropriate confirmation/recovery path.
- **BTN-028** Test current and supported browsers/devices plus assistive technology combinations; do not rely on hover, color, animation, or pointer precision alone.

[Back to Choice, action, and navigation controls index](../../controls-choice-action.md)
