diff options
author | Michael Lando <ml636r@att.com> | 2017-08-07 10:19:02 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2017-08-07 10:19:02 +0000 |
commit | 976626d62ae4f55f9d9f0e96bc954102dd38e726 (patch) | |
tree | 881b58240dd6add92d01ac140f89c305fa0cda06 /catalog-model | |
parent | 3b1119ca51ea0de0ff28b76b916fa8b0cba54fcf (diff) | |
parent | b2c60183d5d654b945a24ec5564807e4f691c6e8 (diff) |
Merge "[SDC] code sync"
Diffstat (limited to 'catalog-model')
3 files changed, 18 insertions, 1 deletions
diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsontitan/operations/ArtifactsOperations.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsontitan/operations/ArtifactsOperations.java index b8d8cb39de..07c2f8d51c 100644 --- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsontitan/operations/ArtifactsOperations.java +++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/jsontitan/operations/ArtifactsOperations.java @@ -269,6 +269,8 @@ public class ArtifactsOperations extends BaseOperation { } else { updateVersionAndDate(artifactData, oldVesrion); } + long time = System.currentTimeMillis(); + artifactData.setHeatParamsUpdateDate(time); break; case HEAT: case HEAT_NET: diff --git a/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverter.java b/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverter.java index c8fac11b3a..3f2b6eabf7 100644 --- a/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverter.java +++ b/catalog-model/src/main/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverter.java @@ -45,7 +45,6 @@ public class HeatStringConverter implements PropertyValueConverter { coverted = ValidationUtils.normaliseWhitespace(coverted); coverted = ValidationUtils.stripOctets(coverted); coverted = ValidationUtils.removeHtmlTagsOnly(coverted); - coverted = coverted.replaceAll("\"", "").replaceAll("\'", ""); } return coverted; } diff --git a/catalog-model/src/test/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverterTest.java b/catalog-model/src/test/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverterTest.java new file mode 100644 index 0000000000..285dd9a965 --- /dev/null +++ b/catalog-model/src/test/java/org/openecomp/sdc/be/model/tosca/converters/HeatStringConverterTest.java @@ -0,0 +1,16 @@ +package org.openecomp.sdc.be.model.tosca.converters; + +import org.junit.Test; + +import static org.junit.Assert.assertEquals; + +public class HeatStringConverterTest { + + @Test + public void convertString_strWithQuotes_returnStringAsIs() { + String str = "'i'm string with \"quote\"'"; + String convert = HeatStringConverter.getInstance().convert(str, null, null); + assertEquals(str, convert); + } + +} |