Add Create Model 48/75948/1
authorBrian Freeman <bf1936@att.com>
Thu, 17 Jan 2019 18:48:16 +0000 (13:48 -0500)
committerBrian Freeman <bf1936@att.com>
Thu, 17 Jan 2019 18:48:23 +0000 (13:48 -0500)
Issue-ID: INT-808
Change-Id: I009cb83315d6310cb244d7ec422a9c90c54bbb5a
Signed-off-by: Brian Freeman <bf1936@att.com>
robot/assets/templates/clamp/create_model.template [new file with mode: 0644]
robot/resources/clamp_interface.robot
robot/testsuites/clamp.robot

diff --git a/robot/assets/templates/clamp/create_model.template b/robot/assets/templates/clamp/create_model.template
new file mode 100644 (file)
index 0000000..dfa628c
--- /dev/null
@@ -0,0 +1 @@
+{"name":"${MODEL_NAME}","controlNamePrefix":"ClosedLoop-","bpmnText":"","propText":"{}","imageText":"<svg xmlns=\"http://www.w3.org/2000/svg\" xmlns:xlink=\"http://www.w3.org/1999/xlink\" version=\"1.1\" width=\"100%\" height=\"100%\">\n\t\t<defs>\n\t\t\t\t<marker viewBox=\"0 0 20 20\" markerWidth=\"10\" markerHeight=\"10\" orient=\"auto\" refX=\"11\" refY=\"10\" id=\"markerSjdype4kmnw\">\n\t\t\t\t\t\t<path d=\"M 1 5 L 11 10 L 1 15 Z\" style=\"stroke-width: 1; stroke-linecap: round; stroke-dasharray: 10000, 1;\" fill=\"#000000\"></path>\n\t\t\t\t</marker>\n\t\t\t\t<marker viewBox=\"0 0 20 20\" markerWidth=\"20\" markerHeight=\"20\" orient=\"auto\" refX=\"6\" refY=\"6\" id=\"markerSjdype4kmny\">\n\t\t\t\t\t\t<circle cx=\"6\" cy=\"6\" r=\"3.5\" style=\"stroke-width: 1; stroke-linecap: round; stroke-dasharray: 10000, 1;\" fill=\"#ffffff\" stroke=\"#000000\"></circle>\n\t\t\t\t</marker>\n\t\t\t\t<marker viewBox=\"0 0 20 20\" markerWidth=\"20\" markerHeight=\"20\" orient=\"auto\" refX=\"8.5\" refY=\"5\" id=\"markerSjdype4kmo0\">\n\t\t\t\t\t\t<path d=\"m 1 5 l 0 -3 l 7 3 l -7 3 z\" style=\"stroke-width: 1; stroke-linecap: butt; stroke-dasharray: 10000, 1;\" fill=\"#ffffff\" stroke=\"#000000\"></path>\n\t\t\t\t</marker>\n\t\t\t\t<marker viewBox=\"0 0 20 20\" markerWidth=\"10\" markerHeight=\"10\" orient=\"auto\" refX=\"11\" refY=\"10\" id=\"markerSjdype4kmo2\">\n\t\t\t\t\t\t<path d=\"M 1 5 L 11 10 L 1 15\" style=\"stroke-width: 1; stroke-linecap: round; stroke-dasharray: 10000, 1;\" fill=\"#ffffff\" stroke=\"#000000\"></path>\n\t\t\t\t</marker>\n\t\t\t\t<marker viewBox=\"0 0 20 20\" markerWidth=\"10\" markerHeight=\"10\" orient=\"auto\" refX=\"-1\" refY=\"10\" id=\"markerSjdype4kmo4\">\n\t\t\t\t\t\t<path d=\"M 0 10 L 8 6 L 16 10 L 8 14 Z\" style=\"stroke-width: 1; stroke-linecap: round; stroke-dasharray: 10000, 1;\" fill=\"#ffffff\" stroke=\"#000000\"></path>\n\t\t\t\t</marker>\n\t\t\t\t<marker viewBox=\"0 0 20 20\" markerWidth=\"10\" markerHeight=\"10\" orient=\"auto\" refX=\"-5\" refY=\"10\" id=\"markerSjdype4kmo6\">\n\t\t\t\t\t\t<path d=\"M 1 4 L 5 16\" style=\"stroke-width: 1; stroke-linecap: round; stroke-dasharray: 10000, 1;\" fill=\"#000000\" stroke=\"#000000\"></path>\n\t\t\t\t</marker>\n\t\t</defs>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"StartEvent_1\" transform=\"matrix(1,0,0,1,50,162)\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"48\" height=\"48\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<circle cx=\"18\" cy=\"18\" r=\"18\" style=\"stroke-width: 2;\" stroke=\"#000000\" fill=\"#ffffff\"></circle>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"36\" height=\"36\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"StartEvent_1_label\" transform=\"matrix(1,0,0,1,23,198)\" style=\"display: none;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"102\" height=\"32\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 11px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"45\" y=\"0\"></tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"90\" height=\"20\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"VesCollector_1g9cmz0\" transform=\"matrix(1,0,0,1,207,140)\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"132\" height=\"92\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"120\" height=\"80\" rx=\"0\" ry=\"0\" style=\"stroke-width: 2;\" stroke=\"#000000\" fill=\"#ffffff\"></rect>\n\t\t\t\t\t\t\t\t<polyline points=\"120,80 120,20 \" style=\"stroke-width: 2;\" fill=\"none\" stroke=\"#000000\"></polyline>\n\t\t\t\t\t\t\t\t<polyline points=\"20,0 20,80 \" style=\"stroke-width: 2;\" fill=\"none\" stroke=\"#000000\"></polyline>\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 12px;\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"5\" y=\"14\">V</tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 12px;\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"5\" y=\"26\">E</tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 12px;\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"5\" y=\"38\">S</tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 12px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"25.5\" y=\"43.5\">VesCollector</tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"120\" height=\"80\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"TCA_1d13unw\" transform=\"matrix(1,0,0,1,453,140)\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"132\" height=\"92\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"120\" height=\"80\" rx=\"0\" ry=\"0\" style=\"stroke-width: 2;\" stroke=\"#000000\" fill=\"#ffffff\"></rect>\n\t\t\t\t\t\t\t\t<polyline points=\"0,60 120,60 \" style=\"stroke-width: 2;\" fill=\"none\" stroke=\"#000000\"></polyline>\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 12px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"48\" y=\"43.5\">TCA</tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"120\" height=\"80\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"Policy_12lup3h\" transform=\"matrix(1,0,0,1,687,140)\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"132\" height=\"92\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"120\" height=\"80\" rx=\"0\" ry=\"0\" style=\"stroke-width: 2;\" stroke=\"#000000\" fill=\"#ffffff\"></rect>\n\t\t\t\t\t\t\t\t<polyline points=\"0,40 60,0 \" style=\"stroke-width: 2;\" fill=\"none\" stroke=\"#000000\"></polyline>\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 12px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"43.5\" y=\"43.5\">Policy</tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"120\" height=\"80\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape selected\" data-element-id=\"EndEvent_16kg9fx\" transform=\"matrix(1,0,0,1,925,162)\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"48\" height=\"48\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<circle cx=\"18\" cy=\"18\" r=\"18\" style=\"stroke-width: 4;\" stroke=\"#000000\" fill=\"#ffffff\"></circle>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"36\" height=\"36\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t\t\t<g class=\" djs-resizer djs-resizer-nw\" transform=\"matrix(1,0,0,1,0,0)\">\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"5\" height=\"5\" class=\" djs-resizer-visual\"></rect>\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"20\" height=\"20\" class=\" djs-resizer-hit\"></rect>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<g class=\" djs-resizer djs-resizer-ne\" transform=\"matrix(0,1,-1,0,36,0)\">\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"5\" height=\"5\" class=\" djs-resizer-visual\"></rect>\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"20\" height=\"20\" class=\" djs-resizer-hit\"></rect>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<g class=\" djs-resizer djs-resizer-se\" transform=\"matrix(-1,0,0,-1,36,36)\">\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"5\" height=\"5\" class=\" djs-resizer-visual\"></rect>\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"20\" height=\"20\" class=\" djs-resizer-hit\"></rect>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<g class=\" djs-resizer djs-resizer-sw\" transform=\"matrix(0,-1,1,0,0,36)\">\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"5\" height=\"5\" class=\" djs-resizer-visual\"></rect>\n\t\t\t\t\t\t\t\t<rect x=\"-7\" y=\"-7\" width=\"20\" height=\"20\" class=\" djs-resizer-hit\"></rect>\n\t\t\t\t\t\t</g>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"EndEvent_16kg9fx_label\" transform=\"matrix(1,0,0,1,898,198)\" style=\"display: none;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"102\" height=\"32\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 11px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"45\" y=\"0\"></tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"90\" height=\"20\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-connection\" data-element-id=\"SequenceFlow_1ahk7jg\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"80\" y=\"174\" width=\"133\" height=\"12\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<path d=\"m  86,180L207,180 \" style=\"stroke-width: 2; stroke-linejoin: round; marker-end: url(&quot;#markerSjdype4kmnw&quot;);\" fill=\"none\" stroke=\"#000000\"></path>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<polyline points=\"86,180 207,180 \" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></polyline>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"SequenceFlow_1ahk7jg_label\" transform=\"matrix(1,0,0,1,101.5,170)\" style=\"display: none;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"102\" height=\"32\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 11px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"45\" y=\"0\"></tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"90\" height=\"20\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-connection\" data-element-id=\"SequenceFlow_18ahat1\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"321\" y=\"174\" width=\"138\" height=\"12\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<path d=\"m  327,180L453,180 \" style=\"stroke-width: 2; stroke-linejoin: round; marker-end: url(&quot;#markerSjdype4kmnw&quot;);\" fill=\"none\" stroke=\"#000000\"></path>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<polyline points=\"327,180 453,180 \" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></polyline>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"SequenceFlow_18ahat1_label\" transform=\"matrix(1,0,0,1,345,170)\" style=\"display: none;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"102\" height=\"32\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 11px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"45\" y=\"0\"></tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"90\" height=\"20\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-connection\" data-element-id=\"SequenceFlow_1mo9gxb\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"567\" y=\"174\" width=\"126\" height=\"12\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<path d=\"m  573,180L687,180 \" style=\"stroke-width: 2; stroke-linejoin: round; marker-end: url(&quot;#markerSjdype4kmnw&quot;);\" fill=\"none\" stroke=\"#000000\"></path>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<polyline points=\"573,180 687,180 \" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></polyline>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"SequenceFlow_1mo9gxb_label\" transform=\"matrix(1,0,0,1,585,170)\" style=\"display: none;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"102\" height=\"32\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 11px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"45\" y=\"0\"></tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"90\" height=\"20\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-connection\" data-element-id=\"SequenceFlow_1dgtrrq\" style=\"display: block;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"801\" y=\"174\" width=\"130\" height=\"12\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<path d=\"m  807,180L925,180 \" style=\"stroke-width: 2; stroke-linejoin: round; marker-end: url(&quot;#markerSjdype4kmnw&quot;);\" fill=\"none\" stroke=\"#000000\"></path>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<polyline points=\"807,180 925,180 \" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></polyline>\n\t\t\t\t</g>\n\t\t</g>\n\t\t<g class=\"djs-group\" xmlns=\"http://www.w3.org/2000/svg\">\n\t\t\t\t<g class=\"djs-element djs-shape\" data-element-id=\"SequenceFlow_1dgtrrq_label\" transform=\"matrix(1,0,0,1,821,170)\" style=\"display: none;\">\n\t\t\t\t\t\t<rect fill=\"none\" class=\"djs-outline\" x=\"-6\" y=\"-6\" width=\"102\" height=\"32\"></rect>\n\t\t\t\t\t\t<g class=\"djs-visual\">\n\t\t\t\t\t\t\t\t<text style=\"font-family: Arial,sans-serif; font-size: 11px;\" class=\" djs-label\">\n\t\t\t\t\t\t\t\t\t\t<tspan x=\"45\" y=\"0\"></tspan>\n\t\t\t\t\t\t\t\t</text>\n\t\t\t\t\t\t</g>\n\t\t\t\t\t\t<rect x=\"0\" y=\"0\" width=\"90\" height=\"20\" style=\"stroke-opacity: 0; stroke-width: 15;\" fill=\"none\" stroke=\"#ffffff\" class=\"djs-hit\"></rect>\n\t\t\t\t</g>\n\t\t</g>\n</svg>","templateName":"${TEMPLATE_NAME}"}
index 4aa87d4..4d29b09 100644 (file)
@@ -3,8 +3,10 @@ Documentation     The main interface for interacting with Microservice Bus.
 Library           RequestsLibrary
 Library           Collections
 Library           String
+Library           JSONUtils
 
 Resource          global_properties.robot
+Resource          json_templater.robot
 
 *** Variables ***
 ${CLAMP_HEALTH_CHECK_PATH}        /restservices/clds/v1/healthcheck
@@ -13,8 +15,19 @@ ${CLAMP_BASE_PATH}   /restservices/clds/v1
 ${CLAMP_CLIENT_KEY}   robot/assets/keys/org.onap.clamp.key.clear.pem
 ${CLAMP_CLIENT_CERT}   robot/assets/keys/org.onap.clamp.cert.pem
 
+${CLAMP_TEMPLATE_PATH}        robot/assets/templates/clamp
+
 
 *** Keywords ***
+Run CLAMP Create Model
+     [Documentation]   Create a new CLAMP Model
+     [Arguments]   ${model_name}   ${template_name}
+     ${dict}=   Create Dictionary   MODEL_NAME=${model_name}      TEMPLATE_NAME=${template_name}
+     ${data}=   Fill JSON Template File    ${CLAMP_TEMPLATE_PATH}/create_model.template    ${dict}
+     ${data_path}=   Set Variable   ${CLAMP_BASE_PATH}/clds/model/${model_name}
+     ${resp}=   Run CLAMP HTTPS Put Request    ${data_path}    ${data}
+     Should Be Equal As Strings  ${resp.status_code}     200
+
 Run CLAMP Get Properties
      [Documentation]   get CLAMP Control Loop properties
      [Arguments]   ${property_id}
@@ -45,6 +58,17 @@ Run CLAMP Health Check
      ${resp}=    Run CLAMP Get Request    ${CLAMP_HEALTH_CHECK_PATH}
      Should Be Equal As Integers        ${resp.status_code}     200
 
+Run CLAMP HTTPS Put Request
+     [Documentation]    Runs CLAMP HTTPS Put request
+     [Arguments]    ${data_path}    ${data}
+     @{client_certs}=    Create List     ${CLAMP_CLIENT_CERT}   ${CLAMP_CLIENT_KEY}
+     ${session}=   Create Client Cert Session  session   ${CLAMP_ENDPOINT}     client_certs=@{client_certs}
+     ${headers}=  Create Dictionary     Accept=application/json    Content-Type=application/json
+     ${resp}=   Put Request     session   ${data_path}   data=${data}  headers=${headers}
+     Should Be Equal As Integers        ${resp.status_code}     200
+     Log    ${resp.json()}
+     [Return]    ${resp}
+
 Run CLAMP HTTPS Get Request
      [Documentation]    Runs CLAMP HTTPS Get request
      [Arguments]    ${data_path}
@@ -63,4 +87,3 @@ Run CLAMP Get Request
      Should Be Equal As Integers        ${resp.status_code}     200
      Log    Received response from CLAMP ${resp.text}
      [Return]    ${resp}
-
index cd86000..407609a 100644 (file)
@@ -11,4 +11,5 @@ Basic CLAMP Health Check
     ${current_model_id}=   Run CLAMP Get Model Names
     ${current_control_loop_id}=   Run CLAMP Get Control Loop    ${current_model_id}
     Run CLAMP Get Properties    ${current_control_loop_id}
-
+    # model_name and template_name will be inputs or config after testing
+    Run CLAMP Create Model   ControlLoopTest3     DCAE-Designer-Template-CLAMPT2VLB_v2_0_vLB0605c122-90f10