diff options
author | Benjamin, Max (mb388a) <mb388a@us.att.com> | 2019-01-20 20:17:45 -0500 |
---|---|---|
committer | Benjamin, Max (mb388a) <mb388a@us.att.com> | 2019-01-20 20:18:09 -0500 |
commit | ed127f2838e19bf104399e92d181a512e6761ee3 (patch) | |
tree | d456f07e28c59e0dddf126d7d729fcebf5c5a832 /common/src/main/java/org/onap | |
parent | 9756b9992858a5f513953f1d16b4d9b396a8397a (diff) |
ensure data for si matches on macro requests
Fixed failing ValidationExceptionTest
Moved MacroRequest.json to test specific folder
Moved resource files to test specific folder
Cleaned up comments from UserParamsValidationTest
Refactored modelInfoValidation method
Removed unused constants from ValidationException
Removed unused ValidationException
ADded overrideExistingMessage boolean
Added test for missing modelType in userParams service object
Fixed failing JUnit tests in MsoRequestTest
Started fixing failing JUnit tests
Began adding validation and tests for userParams modelInfo
Began adding validation for instanceName
Change-Id: I442f6b660af4e716d75746f8d8155aac1e183e80
Issue-ID: SO-1405
Signed-off-by: Benjamin, Max (mb388a) <mb388a@us.att.com>
Diffstat (limited to 'common/src/main/java/org/onap')
-rw-r--r-- | common/src/main/java/org/onap/so/exceptions/ValidationException.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/common/src/main/java/org/onap/so/exceptions/ValidationException.java b/common/src/main/java/org/onap/so/exceptions/ValidationException.java index 713fac70f3..b91c30c598 100644 --- a/common/src/main/java/org/onap/so/exceptions/ValidationException.java +++ b/common/src/main/java/org/onap/so/exceptions/ValidationException.java @@ -32,9 +32,9 @@ public class ValidationException extends Exception { private static final long serialVersionUID = 1L; private static final String VALIDATION_FAIL = "No valid $ELEMENT is specified"; - private static final String INVALID_ELEMENT = "$ELEMENT is not valid in the $VERSION version"; + private static final String UNMATCHED_ELEMENTS = "$ELEMENT does not match $SECOND_ELEMENT"; private static final String REPLACE_ELEMENT_KEY = "\\$ELEMENT"; - private static final String REPLACE_VERSION_KEY = "\\$VERSION"; + private static final String REPLACE_SECOND_ELEMENT_KEY = "\\$SECOND_ELEMENT"; @Deprecated public ValidationException (String msg) { @@ -48,7 +48,7 @@ public class ValidationException extends Exception { public ValidationException (String msg, Exception cause) { super (VALIDATION_FAIL.replaceAll (REPLACE_ELEMENT_KEY, msg), cause); } - public ValidationException(String msg, String version) { - super(INVALID_ELEMENT.replaceAll(REPLACE_ELEMENT_KEY, msg).replaceAll(REPLACE_VERSION_KEY, version)); + public ValidationException(String firstElement, String secondElement) { + super(UNMATCHED_ELEMENTS.replaceAll(REPLACE_ELEMENT_KEY, firstElement).replaceAll(REPLACE_SECOND_ELEMENT_KEY, secondElement)); } -} +}
\ No newline at end of file |