Keyboard

↓ ↑
move between the rows you can see
→
open a feature, then step into it
←
close a feature, or step out to the one above
Enter
go to the page in focus
Tab
the same rows, plus everything else on the page
/
search the whole report
m
open or close the navigation drawer
Esc
leave the search box, or close the drawer
?
this list

Modifying a collection parameter throws

All 3 scenarios hold

A collection that a table passes to a test method is read-only. Adding to a List or a Set throws. Putting into a Map throws. Modifying any collection nested inside them throws. A row's data therefore stays as written, however the test method treats it.

The modification attempted is add for a List or Set, and put for a Map.

expected outcome broken scenario
ScenarioInput valueCollection type?Modification throws?
A list
  • a
  • b
java.util.Listjava.lang.UnsupportedOperationException
A set
  • a
  • b
java.util.Setjava.lang.UnsupportedOperationException
A map
k
a
java.util.Mapjava.lang.UnsupportedOperationException