use of com.vaadin.data.ValueContext in project cia by Hack23.
the class ListPropertyConverterTest method convertToModelVerifyDummyImplTest.
/**
* Convert to model verify dummy impl test.
*/
@Test
public void convertToModelVerifyDummyImplTest() {
final ValueContext context = new ValueContext(Locale.ENGLISH);
final Result<List<?>> convertToModel = new ListPropertyConverter("", null).convertToModel("value", context);
assertNotNull(convertToModel);
assertFalse(convertToModel.isError());
}
use of com.vaadin.data.ValueContext in project cia by Hack23.
the class ListPropertyConverterTest method convertToPresentationTest.
/**
* Convert to presentation test.
*/
@Test
public void convertToPresentationTest() {
final ValueContext context = new ValueContext(Locale.ENGLISH);
final String emptyString = new ListPropertyConverter("partyId", "partyId").convertToPresentation(Arrays.asList(new ViewRiksdagenParty().withPartyId("partyId")), context);
assertEquals("[partyId ]", emptyString);
}
Aggregations