mirror of
https://github.com/apache/struts.git
synced 2026-08-11 01:27:14 +00:00
WW-4536 Drops static to allow redefine the key
(cherry picked from commit 755ad3fadb)
This commit is contained in:
+1
-1
@@ -210,7 +210,7 @@ public class AnnotationActionValidatorManager implements ActionValidatorManager
|
||||
* @param context context
|
||||
* @return a validator key which is the class name plus context.
|
||||
*/
|
||||
protected static String buildValidatorKey(Class clazz, String context) {
|
||||
protected String buildValidatorKey(Class clazz, String context) {
|
||||
ActionInvocation invocation = ActionContext.getContext().getActionInvocation();
|
||||
ActionProxy proxy = invocation.getProxy();
|
||||
ActionConfig config = proxy.getConfig();
|
||||
|
||||
+1
-1
@@ -86,7 +86,7 @@ public class AnnotationActionValidatorManagerTest extends XWorkTestCase {
|
||||
}
|
||||
|
||||
public void testBuildValidatorKey() {
|
||||
String validatorKey = AnnotationActionValidatorManager.buildValidatorKey(SimpleAnnotationAction.class, "name");
|
||||
String validatorKey = annotationActionValidatorManager.buildValidatorKey(SimpleAnnotationAction.class, "name");
|
||||
assertEquals(SimpleAnnotationAction.class.getName() + "/packageName/name", validatorKey);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user