aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/optf-has/has/data/nsi_selection_template_with_create.json19
-rw-r--r--tests/optf-has/has/data/nsi_selection_template_with_nonsi.json19
-rw-r--r--tests/optf-has/has/data/nsi_selection_template_with_reuse.json20
-rw-r--r--tests/optf-has/has/data/nssi_selection_template.json9
-rw-r--r--tests/optf-has/has/data/nssi_selection_template_unmatched.json10
-rw-r--r--tests/optf-has/has/data/nst_selection_template.json55
-rw-r--r--tests/optf-has/has/optf_has_test.robot34
-rw-r--r--tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-keywords.robot2
-rw-r--r--tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-properties.robot2
-rw-r--r--tests/sdnc/sdnc_netconf_tls_post_deploy/sdnc_post_deploy_cert_check.robot21
-rw-r--r--tests/so/etsi/data/responses/expectedVnfPackage.json6
11 files changed, 108 insertions, 89 deletions
diff --git a/tests/optf-has/has/data/nsi_selection_template_with_create.json b/tests/optf-has/has/data/nsi_selection_template_with_create.json
index 6d659f9e..acf53ff6 100644
--- a/tests/optf-has/has/data/nsi_selection_template_with_create.json
+++ b/tests/optf-has/has/data/nsi_selection_template_with_create.json
@@ -26,14 +26,6 @@
"get_param": "reliability"
},
"unit": ""
- },
- {
- "attribute": "coverage_area_ta_list",
- "operator": "eq",
- "threshold": {
- "get_param": "coverage_area_ta_list"
- },
- "unit": ""
}
]
},
@@ -63,8 +55,7 @@
"filtering_attributes": {
"service_profile": {
"latency": {"value": {"get_param": "latency"}, "operator": "lte"},
- "reliability": {"value": {"get_param": "reliability"}, "operator": "gte"},
- "coverage_area_ta_list": {"value": {"get_param": "coverage_area_ta_list"}, "operator": "eq"}
+ "reliability": {"value": {"get_param": "reliability"}, "operator": "gte"}
},
"subnets":{
"core": {
@@ -86,13 +77,6 @@
}
},
"ran": {
- "coverage_area_ta_list": {
- "values": [
- {
- "get_param": "coverage_area_ta_list"
- }
- ]
- },
"latency": {
"max": {
"get_param": "latency"
@@ -155,7 +139,6 @@
"parameters": {
"core_latency": 10,
"core_reliability": 99.9,
- "coverage_area_ta_list": "Chennai",
"latency": 30,
"ran_latency": 7,
"ran_reliability": 99.9,
diff --git a/tests/optf-has/has/data/nsi_selection_template_with_nonsi.json b/tests/optf-has/has/data/nsi_selection_template_with_nonsi.json
index 1b5b99e4..b4e625a2 100644
--- a/tests/optf-has/has/data/nsi_selection_template_with_nonsi.json
+++ b/tests/optf-has/has/data/nsi_selection_template_with_nonsi.json
@@ -26,14 +26,6 @@
"get_param": "reliability"
},
"unit": ""
- },
- {
- "attribute": "coverage_area_ta_list",
- "operator": "eq",
- "threshold": {
- "get_param": "coverage_area_ta_list"
- },
- "unit": ""
}
]
},
@@ -63,8 +55,7 @@
"filtering_attributes": {
"service_profile": {
"latency": {"value": {"get_param": "latency"}, "operator": "lte"},
- "reliability": {"value": {"get_param": "reliability"}, "operator": "gte"},
- "coverage_area_ta_list": {"value": {"get_param": "coverage_area_ta_list"}, "operator": "eq"}
+ "reliability": {"value": {"get_param": "reliability"}, "operator": "gte"}
},
"subnets":{
"core": {
@@ -86,13 +77,6 @@
}
},
"ran": {
- "coverage_area_ta_list": {
- "values": [
- {
- "get_param": "coverage_area_ta_list"
- }
- ]
- },
"latency": {
"max": {
"get_param": "latency"
@@ -155,7 +139,6 @@
"parameters": {
"core_latency": 10,
"core_reliability": 99.9,
- "coverage_area_ta_list": "Chennai",
"latency": 30,
"ran_latency": 7,
"ran_reliability": 99.9,
diff --git a/tests/optf-has/has/data/nsi_selection_template_with_reuse.json b/tests/optf-has/has/data/nsi_selection_template_with_reuse.json
index ff66b2d2..3cce5f9c 100644
--- a/tests/optf-has/has/data/nsi_selection_template_with_reuse.json
+++ b/tests/optf-has/has/data/nsi_selection_template_with_reuse.json
@@ -26,14 +26,6 @@
"get_param": "reliability"
},
"unit": ""
- },
- {
- "attribute": "coverage_area_ta_list",
- "operator": "eq",
- "threshold": {
- "get_param": "coverage_area_ta_list"
- },
- "unit": ""
}
]
},
@@ -63,8 +55,7 @@
"filtering_attributes": {
"service_profile": {
"latency": {"value": {"get_param": "latency"}, "operator": "lte"},
- "reliability": {"value": {"get_param": "reliability"}, "operator": "gte"},
- "coverage_area_ta_list": {"value": {"get_param": "coverage_area_ta_list"}, "operator": "eq"}
+ "reliability": {"value": {"get_param": "reliability"}, "operator": "gte"}
},
"subnets":{
"core": {
@@ -86,13 +77,7 @@
}
},
"ran": {
- "coverage_area_ta_list": {
- "values": [
- {
- "get_param": "coverage_area_ta_list"
- }
- ]
- },
+
"latency": {
"max": {
"get_param": "latency"
@@ -155,7 +140,6 @@
"parameters": {
"core_latency": 10,
"core_reliability": 99.9,
- "coverage_area_ta_list": "Chennai",
"latency": 30,
"ran_latency": 7,
"ran_reliability": 99.9,
diff --git a/tests/optf-has/has/data/nssi_selection_template.json b/tests/optf-has/has/data/nssi_selection_template.json
index a498ca0b..e1656949 100644
--- a/tests/optf-has/has/data/nssi_selection_template.json
+++ b/tests/optf-has/has/data/nssi_selection_template.json
@@ -7,7 +7,6 @@
"template": {
"homing_template_version": "2020-08-13",
"parameters": {
- "coverage_area_ta_list": "Chennai",
"latency": 30,
"reliability": 99.9
},
@@ -51,14 +50,6 @@
"get_param": "reliability"
},
"unit": ""
- },
- {
- "attribute": "coverage_area_ta_list",
- "operator": "eq",
- "threshold": {
- "get_param": "coverage_area_ta_list"
- },
- "unit": ""
}
]
},
diff --git a/tests/optf-has/has/data/nssi_selection_template_unmatched.json b/tests/optf-has/has/data/nssi_selection_template_unmatched.json
index 49302801..23500c5b 100644
--- a/tests/optf-has/has/data/nssi_selection_template_unmatched.json
+++ b/tests/optf-has/has/data/nssi_selection_template_unmatched.json
@@ -7,7 +7,6 @@
"template": {
"homing_template_version": "2020-08-13",
"parameters": {
- "coverage_area_ta_list": "Chennai",
"latency": 5,
"reliability": 99.9
},
@@ -51,15 +50,8 @@
"get_param": "reliability"
},
"unit": ""
- },
- {
- "attribute": "coverage_area_ta_list",
- "operator": "eq",
- "threshold": {
- "get_param": "coverage_area_ta_list"
- },
- "unit": ""
}
+
]
},
"type": "threshold"
diff --git a/tests/optf-has/has/data/nst_selection_template.json b/tests/optf-has/has/data/nst_selection_template.json
new file mode 100644
index 00000000..41819141
--- /dev/null
+++ b/tests/optf-has/has/data/nst_selection_template.json
@@ -0,0 +1,55 @@
+{
+ "name":"urllc_sample",
+ "files":{
+
+ },
+ "limit":10,
+ "num_solution":"1",
+ "timeout":1200,
+ "template":{
+ "homing_template_version":"2020-08-13",
+ "demands":{
+ "nst_demand":[
+ {
+ "inventory_provider":"aai",
+ "inventory_type":"nst",
+ "unique":"true",
+ "region":"RegionOne",
+ "filtering_attributes":{
+ "model-role":"nst"
+ }
+ }
+ ]
+ },
+ "constraints":{
+ "nst_Threshold":{
+ "type":"threshold",
+ "demands":[
+ "nst_demand"
+ ],
+ "properties":{
+ "evaluate":[
+ {
+ "attribute":"latency",
+ "operator":"lte",
+ "threshold":30,
+ "unit":"ms"
+ }
+ ]
+ }
+ } },
+ "optimization":{
+ "goal": "minimize",
+ "operation_function": {
+ "operator": "sum",
+ "operands": [{
+ "function": "attribute",
+ "params": {
+ "demand": "nst_demand",
+ "attribute": "latency"
+ }
+ }]
+ }
+ }
+ }
+} \ No newline at end of file
diff --git a/tests/optf-has/has/optf_has_test.robot b/tests/optf-has/has/optf_has_test.robot
index 9185fcea..6085bcea 100644
--- a/tests/optf-has/has/optf_has_test.robot
+++ b/tests/optf-has/has/optf_has_test.robot
@@ -686,6 +686,40 @@ GetPlanWithNssiSelectionUnmatched
Should Be Equal As Integers ${resp.status_code} 200
Should Be Equal not found ${resultStatus}
+# NST selection template
+SendPlanWithNSTSelection
+ [Documentation] It sends a POST request to conductor
+ Create Session optf-cond ${COND_HOSTNAME}:${COND_PORT}
+ ${data}= Get Binary File ${CURDIR}${/}data${/}nst_selection_template.json
+ &{headers}= Create Dictionary Authorization=${HAS_Auth} Content-Type=application/json Accept=application/json
+ ${resp}= Post Request optf-cond /v1/plans data=${data} headers=${headers}
+ Log To Console *********************
+ Log To Console response = ${resp}
+ Log To Console body = ${resp.text}
+ ${response_json} json.loads ${resp.content}
+ ${generatedPlanId}= Convert To String ${response_json['id']}
+ Set Global Variable ${generatedPlanId}
+ Log To Console generatedPlanId = ${generatedPlanId}
+ Should Be Equal As Integers ${resp.status_code} 201
+ Sleep 60s Wait Plan Resolution
+
+GetPlanWithNsTSelection
+ [Documentation] It sends a REST GET request to capture recommendations
+ Create Session optf-cond ${COND_HOSTNAME}:${COND_PORT}
+ &{headers}= Create Dictionary Authorization=${HAS_Auth} Content-Type=application/json Accept=application/json
+ ${resp}= Get Request optf-cond /v1/plans/${generatedPlanId} headers=${headers}
+ Log To Console *********************
+ Log To Console response = ${resp}
+ ${response_json} json.loads ${resp.content}
+ ${resultStatus}= Convert To String ${response_json['plans'][0]['status']}
+ ${instance_name}= Convert To String ${response_json['plans'][0]['recommendations'][0]['nst_demand']['candidate']['model_name']}
+ Set Global Variable ${resultStatus}
+ Log To Console resultStatus = ${resultStatus}
+ Log To Console body = ${resp.text}
+ Should Be Equal As Integers ${resp.status_code} 200
+ Should Be Equal done ${resultStatus}
+ Should Be Equal EmbbNst ${instance_name}
+
*** Keywords ***
diff --git a/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-keywords.robot b/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-keywords.robot
index 52cc5d2f..3ea61649 100644
--- a/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-keywords.robot
+++ b/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-keywords.robot
@@ -55,8 +55,6 @@ Send Get Request And Validate TLS Connection Response
&{headers1}= Create Dictionary Authorization=Basic YWRtaW46S3A4Yko0U1hzek0wV1hsaGFrM2VIbGNzZTJnQXc4NHZhb0dHbUp2VXkyVQ== Content-Type=application/json Accept=application/json
${resp1}= Get Request sdnc_restconf ${PNFSIM_MOUNT_PATH} headers=${headers1}
Should Be Equal As Strings ${resp1.status_code} ${resp_code}
- Should Contain ${resp1.content} netconf-id
- Should Contain ${resp1.content} netconf-param
Send Delete Request And Validate PNF Mount Deleted
[Documentation] Send request to passed url and validate received response
diff --git a/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-properties.robot b/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-properties.robot
index e6e9790c..2f2d6f5a 100644
--- a/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-properties.robot
+++ b/tests/sdnc/sdnc_netconf_tls_post_deploy/resources/sdnc-properties.robot
@@ -28,7 +28,7 @@ ${SDNC_NETWORK_TOPOLOGY} /config/network-topology:network-topolo
${MOUNT_PATH} %{WORKSPACE}/tests/sdnc/sdnc_netconf_tls_post_deploy/cert-data
${SDNC_CSR_FILE} %{WORKSPACE}/tests/sdnc/sdnc_netconf_tls_post_deploy/csr/sdnc_csr.env
${SDNC_MOUNT_PATH} /config/network-topology:network-topology/topology/topology-netconf/node/PNFDemo
-${PNFSIM_MOUNT_PATH} /config/network-topology:network-topology/topology/topology-netconf/node/PNFDemo/yang-ext:mount/pnf-simulator
+${PNFSIM_MOUNT_PATH} /config/network-topology:network-topology/topology/topology-netconf/node/PNFDemo/yang-ext:mount/turing-machine:turing-machine
# Netconf-Pnp-Simulator
${NETCONF_PNP_SIM_CONTAINER_NAME} %{NETCONF_PNP_SIM_CONTAINER_NAME}
diff --git a/tests/sdnc/sdnc_netconf_tls_post_deploy/sdnc_post_deploy_cert_check.robot b/tests/sdnc/sdnc_netconf_tls_post_deploy/sdnc_post_deploy_cert_check.robot
index 7d322c1b..4d935974 100644
--- a/tests/sdnc/sdnc_netconf_tls_post_deploy/sdnc_post_deploy_cert_check.robot
+++ b/tests/sdnc/sdnc_netconf_tls_post_deploy/sdnc_post_deploy_cert_check.robot
@@ -14,15 +14,14 @@ Check SDNC Keystore For Netopeer2 Certificates
[Documentation] Checking Keystore after SDNC istallation
Send Get Request And Validate Response Sdnc ${SDNC_KEYSTORE_CONFIG_PATH} 200
-# TLS connection to netconf simulator is not currently working. Commenting
-# out for now, and will uncomment when we have working solution.
-#Check SDNC And PNF TLS Connection Over Netopeer2 Certificates
-# [Tags] SDNC-PNF-TLS-CONNECTION-CHECK
-# [Documentation] Checking PNF Mount after SDNC Installation
-# Send Get Request And Validate TLS Connection Response ${SDNC_MOUNT_PATH} 200
-
-#Check PNF Delete And Remove Netopeer2 Certificates From Keystore
-# [Tags] SDNC-PNF-MOUNT-DELETE-CLEAR-KEYSTORE
-# [Documentation] Checking PNF Mount Delete from SDNC
-# Send Delete Request And Validate PNF Mount Deleted ${SDNC_MOUNT_PATH} 200
+
+Check SDNC And PNF TLS Connection Over Netopeer2 Certificates
+ [Tags] SDNC-PNF-TLS-CONNECTION-CHECK
+ [Documentation] Checking PNF Mount after SDNC Installation
+ Send Get Request And Validate TLS Connection Response ${SDNC_MOUNT_PATH} 200
+
+Check PNF Delete And Remove Netopeer2 Certificates From Keystore
+ [Tags] SDNC-PNF-MOUNT-DELETE-CLEAR-KEYSTORE
+ [Documentation] Checking PNF Mount Delete from SDNC
+ Send Delete Request And Validate PNF Mount Deleted ${SDNC_MOUNT_PATH} 200
diff --git a/tests/so/etsi/data/responses/expectedVnfPackage.json b/tests/so/etsi/data/responses/expectedVnfPackage.json
index 41eeb8b1..c97865ee 100644
--- a/tests/so/etsi/data/responses/expectedVnfPackage.json
+++ b/tests/so/etsi/data/responses/expectedVnfPackage.json
@@ -10,13 +10,13 @@
"operationalState": "ENABLED",
"_links": {
"self": {
- "href": "http://so-vnfm-adapter.onap:9092/so/vnfm-adapter/v1/vnfpkgm/v1/vnf_packages/73522444-e8e9-49c1-be29-d355800aa349"
+ "href": "http://so-etsi-sol003-adapter.onap:9092/so/vnfm-adapter/v1/vnfpkgm/v1/vnf_packages/73522444-e8e9-49c1-be29-d355800aa349"
},
"vnfd": {
- "href": "http://so-vnfm-adapter.onap:9092/so/vnfm-adapter/v1/vnfpkgm/v1/vnf_packages/73522444-e8e9-49c1-be29-d355800aa349/vnfd"
+ "href": "http://so-etsi-sol003-adapter.onap:9092/so/vnfm-adapter/v1/vnfpkgm/v1/vnf_packages/73522444-e8e9-49c1-be29-d355800aa349/vnfd"
},
"packageContent": {
- "href": "http://so-vnfm-adapter.onap:9092/so/vnfm-adapter/v1/vnfpkgm/v1/vnf_packages/73522444-e8e9-49c1-be29-d355800aa349/package_content"
+ "href": "http://so-etsi-sol003-adapter.onap:9092/so/vnfm-adapter/v1/vnfpkgm/v1/vnf_packages/73522444-e8e9-49c1-be29-d355800aa349/package_content"
}
}
}