summaryrefslogtreecommitdiffstats
path: root/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src
diff options
context:
space:
mode:
Diffstat (limited to 'openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src')
-rw-r--r--openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java
index 068e147874..13f2d638d2 100644
--- a/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java
+++ b/openecomp-be/lib/openecomp-sdc-validation-lib/openecomp-sdc-validation-sdk/src/main/java/org/openecomp/sdc/validation/util/ValidationTestUtil.java
@@ -21,7 +21,7 @@ import org.openecomp.sdc.validation.ResourceValidator;
import org.openecomp.sdc.validation.ValidationContext;
import org.openecomp.sdc.validation.Validator;
import org.openecomp.sdc.validation.base.ResourceBaseValidator;
-import org.testng.Assert;
+
import java.io.File;
import java.io.FileInputStream;
@@ -169,9 +169,11 @@ public class ValidationTestUtil {
}
public static void validateErrorMessage(String actualMessage, String expected, String... params) {
- Assert.assertEquals(actualMessage.replace("\n", "").replace("\r", ""),
+ if (!Objects.equals(actualMessage.replace("\n", "").replace("\r", ""),
ErrorMessagesFormatBuilder.getErrorWithParameters(expected, params).replace("\n", "")
- .replace("\r", ""));
+ .replace("\r", ""))){
+ throw new RuntimeException("validation failed");
+ }
}