### Question:
PageSizeEditor extends PropertyEditorSupport { @Override public void setAsText(String text) { for (int pageSize : JCUser.PAGE_SIZES_AVAILABLE) { if (String.valueOf(pageSize).equals(text)) { setValue(pageSize); return; } } }  @Override void setAsText(String text);  }### Answer:
@Test public void userSetInvalidValue() { editor.setAsText("bla"); assertEquals(null, editor.getValue()); }
@Test public void userSetValueWhichOutOfRange() { editor.setAsText(String.valueOf(1)); assertEquals(null, editor.getValue()); }
@Test public void userSetValidValue() { int expected = 25; editor.setAsText(String.valueOf(expected)); assertEquals(expected, editor.getValue()); }