assertThat(selectOptions.get(1).getSelected(), is("true"));
}
@Test
public void shouldSelectManyEnum() throws Exception {
SelectManyEnumSelectItemsPage page = this.pages.get(SelectManyEnumSelectItemsPage.class);
List<SelectOption> selectOptions = page.getSelectOptions();
assertThat(selectOptions.size(), is(3));
assertThat(selectOptions.get(0).getValue(), is("JAVA"));
assertThat(selectOptions.get(0).getSelected(), is(nullValue()));
assertThat(selectOptions.get(0).getText(), is("Java"));
assertThat(selectOptions.get(1).getValue(), is("SPRING"));
assertThat(selectOptions.get(1).getSelected(), is(nullValue()));
assertThat(selectOptions.get(1).getText(), is("Spring"));
assertThat(selectOptions.get(2).getValue(), is("JAVASERVER_FACES"));
assertThat(selectOptions.get(2).getSelected(), is(nullValue()));
assertThat(selectOptions.get(2).getText(), is("JavaServer Faces"));
page.selectSecondOption();
page = (SelectManyEnumSelectItemsPage) page.clickSubmitButton();
selectOptions = page.getSelectOptions();
assertThat(selectOptions.size(), is(3));
assertThat(selectOptions.get(0).getSelected(), is(nullValue()));
assertThat(selectOptions.get(1).getSelected(), is("true"));
}