### Question:
DayTimeSelector implements TypedValueSelector { @Override public String getValue() { final DayTimeValue value = view.getValue(); return value.isEmpty() ? "" : converter.toDMNString(value); } @Inject  DayTimeSelector(final DayTimeSelector.View view,
                           final DayTimeValueConverter converter); @Override String getValue(); @Override void setValue(final String value); @Override void setPlaceholder(final String placeholder); @Override Element getElement(); @Override void setOnInputChangeCallback(final Consumer<Event> onValueChanged); @Override void setOnInputBlurCallback(final Consumer<BlurEvent> onValueInputBlur); @Override void select(); @Override String toDisplay(final String rawValue);  }### Answer:
@Test public void testGetValue() { final DayTimeValue value = mock(DayTimeValue.class); final String expected = "dmnString"; when(view.getValue()).thenReturn(value); when(converter.toDMNString(value)).thenReturn(expected); when(value.isEmpty()).thenReturn(false); final String actual = dayTimeSelector.getValue(); assertEquals(expected, actual); }
@Test public void testGetValueWhenValueIsEmpty() { final DayTimeValue value = mock(DayTimeValue.class); final String expected = ""; when(view.getValue()).thenReturn(value); when(value.isEmpty()).thenReturn(true); final String actual = dayTimeSelector.getValue(); assertEquals(expected, actual); }