Fix failing test
This commit is contained in:
parent
8a043ae9aa
commit
bd69390c0f
|
@ -138,7 +138,14 @@ import org.springframework.web.servlet.mvc.support.RedirectAttributes;
|
|||
import org.springframework.web.servlet.support.RequestContextUtils;
|
||||
import org.springframework.web.servlet.view.InternalResourceViewResolver;
|
||||
|
||||
import static org.junit.Assert.*;
|
||||
import static org.junit.Assert.assertArrayEquals;
|
||||
import static org.junit.Assert.assertEquals;
|
||||
import static org.junit.Assert.assertFalse;
|
||||
import static org.junit.Assert.assertNotNull;
|
||||
import static org.junit.Assert.assertNull;
|
||||
import static org.junit.Assert.assertSame;
|
||||
import static org.junit.Assert.assertTrue;
|
||||
import static org.junit.Assert.fail;
|
||||
|
||||
/**
|
||||
* @author Rossen Stoyanchev
|
||||
|
@ -2230,11 +2237,10 @@ public class ServletAnnotationControllerHandlerMethodTests extends AbstractServl
|
|||
static class MyWebBindingInitializer implements WebBindingInitializer {
|
||||
|
||||
@Override
|
||||
public void initBinder(WebDataBinder binder, WebRequest request) {
|
||||
public void initBinder(WebDataBinder binder) {
|
||||
LocalValidatorFactoryBean vf = new LocalValidatorFactoryBean();
|
||||
vf.afterPropertiesSet();
|
||||
binder.setValidator(vf);
|
||||
assertNotNull(request.getLocale());
|
||||
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
|
||||
dateFormat.setLenient(false);
|
||||
binder.registerCustomEditor(Date.class, new CustomDateEditor(dateFormat, false));
|
||||
|
|
Loading…
Reference in New Issue