com.vaadin.flow.component.combobox.
Class MultiSelectComboBoxTester<T extends MultiSelectComboBox<Y>,Y>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the currently selected item.
Get the actual items for the dropdown as a List.
Get dropdown suggestions as String representations sent to the client.
void
selectItem
(String... selection) Select items by client string representation.
void
Simulate writing a filter to the combobox.
Methods inherited from class com.vaadin.testbench.unit.ComponentTester
ensureComponentIsUsable, ensureComponentIsUsable, ensureVisible, ensureVisible, find, findAllByQuery, findByQuery, fireDomEvent, fireDomEvent, fireDomEvent, getComponent, getField, getField, getMethod, getMethod, isUsable, isUsable, notUsableReasons, notUsableReasons, roundTrip, setModal, setValueAsUser
-
Constructor Details
-
MultiSelectComboBoxTester
Wrap given component for testing.
Parameters:
component
- target component
-
-
Method Details
-
setFilter
Simulate writing a filter to the combobox.
Use
getSuggestions()
to get the string values show in the dropdown orgetSuggestionItems()
to get the actual items in the suggestion.Parameters:
filter
- string to use for filtering -
selectItem
Select items by client string representation.
Parameters:
selection
- item representations as strings -
getSelected
Get the currently selected item.
Returns:
current selection
-
getSuggestions
Get dropdown suggestions as String representations sent to the client. Any filter that is set is taken into account.
Returns:
List of item representation strings
-
getSuggestionItems
Get the actual items for the dropdown as a List. Any filter that is set is taken into account.
Returns:
List of items
-