Package limn.testing.a11y
Class MenuContract
java.lang.Object
limn.testing.a11y.MenuContract
What every widget of the
MENU shape owes a reader, as named cases over a
MenuSubject: a menu bar and a popup menu under the same rules, which until this were
tested in each widget's own file.
- the rows are the members of one selection, named in order, and classify as
MENU; - the four invariants hold, unfocused and focused;
FOCUSmoves the highlight onto a row and chooses nothing and opens nothing; a disabled row offers it not;- a row with something to open offers
SHOW_MENUandEXPANDwhile closed andCOLLAPSEalone while open, each verb doing what it says and the other refused by state; a row with nothing to open offers none of the three; PRESSchooses a command row andTOGGLEflips a check row, which takesPRESStoo; a title, a submenu and an empty one take neither;- a row's verbs are the menu verb set and nothing else, and a disabled row carries none;
- a row keeps its id while the highlight moves.
perform answers true whenever the node
exists, so what the contract checks after a refused verb is that nothing changed.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Set<Accessible.Action> The verbs a menu row may carry. -
Method Summary
Modifier and TypeMethodDescriptionstatic List<ContractCase> cases(MenuSubject subject, UiRuntime runtime) The cases, in the order above.
-
Field Details
-
ROW_VERBS
The verbs a menu row may carry.
-
-
Method Details
-
cases
The cases, in the order above.- Parameters:
subject- the widget under contractruntime- the installed runtime the harness drains verbs through- Returns:
- the cases; a test runs each as a dynamic test
-