diff options
-rw-r--r-- | README.md | 52 | ||||
-rw-r--r-- | src/test/java/org/onap/sdc/impl/MyTest.java (renamed from src/test/java/org/onap/sdc/impl/myTest.java) | 4 |
2 files changed, 42 insertions, 14 deletions
@@ -16,28 +16,56 @@ It uses the underlying generic JTOSCA parser. ONAP SDC-Tosca can be compiled easily using maven command: `mvn clean install` The result is JAR file under "target" folder +# Testing a CSAR locally +to run the parser locally you can use the MyTest Junit test to easily execute the parser on your own input. + +1. to run it place your csar in **sdc-tosca\src\test\resources\csars** + +2. Go to the test class located at **sdc-tosca\src\test\java\org\onap\sdc\impl\MyTest.java** + +3. un comment the logic ther and update the csar name you plced in the step above: +```java +SdcToscaParserFactory factory = SdcToscaParserFactory.getInstance(); +ISdcCsarHelper = getCsarHelper("csars/<your csar name example my.csar>"); + +//example of functions +//get node type by name +List<NodeTemplate> serviceNodeTemplatesByType = fdntCsarHelper.getServiceNodeTemplatesByType("org.openecomp.nodes.ForwardingPath"); +//get node type property +String target_range = fdntCsarHelper.getNodeTemplatePropertyLeafValue(serviceNodeTemplatesByType.get(0), "target_range"); + +``` + # Getting Help -*** to be completed on release *** -SDC@lists.onap.org +##### [Mailing list](mailto:onap-sdc@lists.onap.org) + -SDC Javadoc and Maven site - -*** to be completed on rrelease *** -# Release notes for versions +##### [JIRA](http://jira.onap.org) + + + +##### [WIKI](https://wiki.onap.org/display/DW/Service+Design+and+Creation+%28SDC%29+Portal) + +##### [TOSCA Prser AID]((https://wiki.onap.org/display/DW/Service+Design+and+Creation+%28SDC%29+Portal)) + + + + -1.1.31-SNAPSHOT -Initial after separating into separate repo +# Release notes +## 1.4.1 +### Features: +1. **disable max conformance level validation**: until this version the parser had the definition of the max and min conformance level of the CSAR version which it supports. + the conformance level is generated by sdc and as a result the two had to be aligned, over wise the CSAR will fail on parsing. + from this version the max version will no longer be checked by the parser. +2. **Operations support**: add support for parsing the Operations in the tosca models. -------------------------------- -1.1.1-SNAPSHOT -Added toString of Function (GetInput, etc.) -Allowed two arguments for GetInput - name of list input and index in list diff --git a/src/test/java/org/onap/sdc/impl/myTest.java b/src/test/java/org/onap/sdc/impl/MyTest.java index 4833f6f..cdd36cb 100644 --- a/src/test/java/org/onap/sdc/impl/myTest.java +++ b/src/test/java/org/onap/sdc/impl/MyTest.java @@ -10,13 +10,13 @@ import java.io.File; import static org.onap.sdc.impl.SdcToscaParserBasicTest.getCsarHelper; -public class myTest { +public class MyTest { static SdcToscaParserFactory factory; static ISdcCsarHelper fdntCsarHelper; @Test - public void testNoValidationIssues() throws SdcToscaParserException { + public void testMyCsar() throws SdcToscaParserException { // factory = SdcToscaParserFactory.getInstance(); |