converter.setTargetClass(Integer.class);
replay(converter);
BindableBean form = new BindableBean();
TargetBean targetBean = new TargetBean();
form.setTargetBean(targetBean);
handler.bindInwards(form, form, 4);
Assert.assertEquals(targetBean.getIntegerProperty().intValue(), 4);
verify(converter);
reset(converter);
converter.setTargetClass(Integer.class);
replay(converter);
handler.bindInwards(form, form, ConversionState.NULL);
Assert.assertEquals(targetBean.getIntegerProperty(), null);
verify(converter);
reset(converter);
converter.setTargetClass(Integer.class);
expect(converter.toTargetType(null)).andReturn(null);
replay(converter);
handler.bindInwards(form, form, ConversionState.FAILURE);
Assert.assertEquals(targetBean.getIntegerProperty(), null);
verify(converter);
}