public void testValidate_WithPageSetting() {
ConfigurablePageBeanValidator validator = getValidator(0);
FooBean bean = new FooBean();
BindException errors = new BindException(bean, "pagedFooBean");
validator.validate(bean, errors);
assertTrue(errors.hasFieldErrors("name"));
assertTrue(errors.hasFieldErrors("name"));
assertEquals(1, errors.getErrorCount());
assertEquals("name", ((FieldError) errors.getAllErrors().iterator().next()).getField());
errors = new BindException(bean, "pagedFooBean");
bean.setName("name");
validator.validate(bean, errors);
assertFalse(errors.hasFieldErrors("name"));
}