use of de.diedavids.sneferu.components.descriptor.TableComponentDescriptor in project jmix-sneferu by mariodavid.
the class SelectInListInteractionTest method when_interactionIsPerformedWithMultiSelection_then_allValuesAreSet.
@Test
void when_interactionIsPerformedWithMultiSelection_then_allValuesAreSet(UiTestAPI uiTestAPI) {
// given:
final PetType ice = storePetType("Ice");
final PetType water = storePetType("Water");
final PetType dragon = storePetType("Dragon");
// and:
final StandardLookupTestAPI<PetType, PetTypeBrowse> openedScreen = uiTestAPI.openStandardLookup(PetType.class, PetTypeBrowse.class);
final TableComponentDescriptor table = table("table");
assertThat(openedScreen.rawComponent(table).isMultiSelect()).isTrue();
// when:
openedScreen.interact(selectInList(table, Lists.list(water, dragon)));
// then:
final Set<PetType> selectedPetTypesInTable = openedScreen.rawComponent(table).getSelected();
// and:
assertThat(selectedPetTypesInTable).contains(water, dragon);
}
Aggregations