### Question:
SelectItems implements Iterable<SelectItem> { protected String getStringValue(Object o) { return o == null ? null : o.toString(); } SelectItems(Object value); @SuppressWarnings({ "rawtypes", "unchecked" }) Iterator<SelectItem> iterator();  }### Answer:
@Test public void shouldGetStringValue() throws Exception { new TestableSelectItems() { @Override public void test() throws Exception { assertThat(getStringValue(new StringBuffer("a")), is("a")); assertThat(getStringValue(new Integer(123)), is("123")); assertThat(getStringValue(null), is(nullValue())); } }.test(); }