mirror of
https://github.com/apache/struts.git
synced 2026-08-07 15:46:57 +00:00
ConversionErrorInterceptor to extend MethodFilterIntercept
See WW-4676
This commit is contained in:
+4
-4
@@ -48,7 +48,7 @@ public class ConversionErrorInterceptorTest extends XWorkTestCase {
|
||||
stack.push(action);
|
||||
mockInvocation.matchAndReturn("getAction", action);
|
||||
assertNull(action.getFieldErrors().get("foo"));
|
||||
interceptor.intercept(invocation);
|
||||
interceptor.doIntercept(invocation);
|
||||
assertTrue(action.hasFieldErrors());
|
||||
assertNotNull(action.getFieldErrors().get("foo"));
|
||||
}
|
||||
@@ -61,7 +61,7 @@ public class ConversionErrorInterceptorTest extends XWorkTestCase {
|
||||
stack.push(action);
|
||||
mockInvocation.matchAndReturn("getAction", action);
|
||||
assertNull(action.getFieldErrors().get(fieldName));
|
||||
interceptor.intercept(invocation);
|
||||
interceptor.doIntercept(invocation);
|
||||
assertTrue(action.hasFieldErrors()); // This fails!
|
||||
assertNotNull(action.getFieldErrors().get(fieldName));
|
||||
}
|
||||
@@ -76,7 +76,7 @@ public class ConversionErrorInterceptorTest extends XWorkTestCase {
|
||||
assertNull(action.getFieldErrors().get("foo"));
|
||||
assertEquals(55, stack.findValue("foo"));
|
||||
|
||||
interceptor.intercept(mai);
|
||||
interceptor.doIntercept(mai);
|
||||
|
||||
assertTrue(action.hasFieldErrors());
|
||||
assertNotNull(action.getFieldErrors().get("foo"));
|
||||
@@ -100,7 +100,7 @@ public class ConversionErrorInterceptorTest extends XWorkTestCase {
|
||||
assertNull(action.getFieldErrors().get("foo"));
|
||||
assertEquals(55, stack.findValue("foo"));
|
||||
|
||||
interceptor.intercept(mai);
|
||||
interceptor.doIntercept(mai);
|
||||
|
||||
assertTrue(action.hasFieldErrors());
|
||||
assertNotNull(action.getFieldErrors().get("foo"));
|
||||
|
||||
Reference in New Issue
Block a user