From a43f31d01e92202e9bbb72ab0556c88790b3ce94 Mon Sep 17 00:00:00 2001 From: "Singal, Kapil (ks220y)" Date: Tue, 4 Sep 2018 13:30:16 -0400 Subject: SDN Controller Blueprints Assignment Creating SDN Controller Blueprints Resource Assignment Service Junit Tests Change-Id: Id0126063292d0ddcecaabe9a192d8dbf2a133098 Issue-ID: CCSDK-506 Signed-off-by: Singal, Kapil (ks220y) --- .../assignments/alltype-empty-value-mapping.json | 86 ++++++++++++++++ .../resources/assignments/alltype-mapping.json | 110 +++++++++++++++++++++ .../resources/assignments/empty-dictionary.json | 1 + 3 files changed, 197 insertions(+) create mode 100644 blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-empty-value-mapping.json create mode 100644 blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-mapping.json create mode 100644 blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/empty-dictionary.json (limited to 'blueprints-processor/plugin/assignment-provider/src/test/resources/assignments') diff --git a/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-empty-value-mapping.json b/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-empty-value-mapping.json new file mode 100644 index 000000000..a3d65927b --- /dev/null +++ b/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-empty-value-mapping.json @@ -0,0 +1,86 @@ +[ + { + "name": "vnf-id-string", + "property": { + "required": true, + "type": "string" + }, + "input-param": true, + "dictionary-name": "vnf-id-string", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-id-integer", + "property": { + "required": true, + "type": "integer" + }, + "input-param": true, + "dictionary-name": "vnf-id-integer", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-boolean", + "property": { + "required": true, + "type": "boolean" + }, + "input-param": true, + "dictionary-name": "vnf-boolean", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-complex", + "property": { + "required": true, + "type": "dt-complex" + }, + "input-param": true, + "dictionary-name": "vnf-complex", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-id-array", + "property": { + "required": true, + "type": "list", + "entry_schema": { + "type": "string" + } + }, + "input-param": true, + "dictionary-name": "vnf-id-array", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-array-complex", + "property": { + "required": true, + "type": "list", + "entry_schema": { + "type": "dt-complex" + } + }, + "input-param": true, + "dictionary-name": "vnf-array-complex", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + } +] diff --git a/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-mapping.json b/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-mapping.json new file mode 100644 index 000000000..36909da99 --- /dev/null +++ b/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/alltype-mapping.json @@ -0,0 +1,110 @@ +[ + { + "name": "vnf-id-string", + "property": { + "required": true, + "type": "string", + "value": "123456" + }, + "input-param": true, + "dictionary-name": "vnf-id-string", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-id-integer", + "property": { + "required": true, + "type": "integer", + "value": 123456 + }, + "input-param": true, + "dictionary-name": "vnf-id-integer", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-boolean", + "property": { + "required": true, + "type": "boolean", + "value": true + }, + "input-param": true, + "dictionary-name": "vnf-boolean", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-complex", + "property": { + "required": true, + "type": "dt-complex", + "value": { + "name": "Brinda", + "location": "Madurai", + "count": 2 + } + }, + "input-param": true, + "dictionary-name": "vnf-complex", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-id-array", + "property": { + "required": true, + "type": "list", + "entry_schema": { + "type": "string" + }, + "value": [ + "A", + "B", + "C" + ] + }, + "input-param": true, + "dictionary-name": "vnf-id-array", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + }, + { + "name": "vnf-array-complex", + "property": { + "required": true, + "type": "list", + "entry_schema": { + "type": "dt-complex" + }, + "value": [ + { + "name": "A" + }, + { + "name": "B" + }, + { + "name": "C" + } + ] + }, + "input-param": true, + "dictionary-name": "vnf-array-complex", + "dictionary-source": "input", + "version": 0, + "status": "success", + "updated-by": "System" + } +] diff --git a/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/empty-dictionary.json b/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/empty-dictionary.json new file mode 100644 index 000000000..0637a088a --- /dev/null +++ b/blueprints-processor/plugin/assignment-provider/src/test/resources/assignments/empty-dictionary.json @@ -0,0 +1 @@ +[] \ No newline at end of file -- cgit 1.2.3-korg