diff options
author | davsad <david.sadlier@est.tech> | 2021-01-29 13:35:59 +0000 |
---|---|---|
committer | Christophe Closset <christophe.closset@intl.att.com> | 2021-01-30 09:21:52 +0000 |
commit | 3cd2fa718e7f0c96988374e0843372d3e48b4659 (patch) | |
tree | 3488abc1ae32013cc289800fc32ecd982457b3e2 /common-app-api/src/test/java | |
parent | 7ceb6f99ee7490cebc0e2641acfe453029875cc0 (diff) |
Fix onboarding artifact name changed
Prevent Yang module filenames with prefix _3gpp losing leading _
Issue-ID: SDC-3415
Signed-off-by: davsad <david.sadlier@est.tech>
Change-Id: I68afb6c8a1ef2fa58a37af20a2119d3b648ba272
Diffstat (limited to 'common-app-api/src/test/java')
-rw-r--r-- | common-app-api/src/test/java/org/openecomp/sdc/common/util/ValidationUtilsTest.java | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/common-app-api/src/test/java/org/openecomp/sdc/common/util/ValidationUtilsTest.java b/common-app-api/src/test/java/org/openecomp/sdc/common/util/ValidationUtilsTest.java index 2d5122a13f..e7aad96f60 100644 --- a/common-app-api/src/test/java/org/openecomp/sdc/common/util/ValidationUtilsTest.java +++ b/common-app-api/src/test/java/org/openecomp/sdc/common/util/ValidationUtilsTest.java @@ -724,6 +724,24 @@ public class ValidationUtilsTest { } @Test + public void validateNormalizeFileNameFor3gppYangModule() { + final String testName = "_3gpptestfile"; + + String result = ValidationUtils.normalizeFileName(testName); + + assertEquals(result, testName); + } + + @Test + public void validateNormalizeFileNameStripLeadingUnderscore() { + final String testName = "_testfile"; + + String result = ValidationUtils.normalizeFileName(testName); + + assertEquals(result, "testfile"); + } + + @Test public void checkValidateUrlReturnsTrueIfURLIsValid() { final String testUrl = "http://test.co/valid/url/"; |