aboutsummaryrefslogtreecommitdiffstats
path: root/tests/so/etsi/etsi_nfvo_ns_lcm_tests.robot
diff options
context:
space:
mode:
Diffstat (limited to 'tests/so/etsi/etsi_nfvo_ns_lcm_tests.robot')
-rw-r--r--tests/so/etsi/etsi_nfvo_ns_lcm_tests.robot27
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/so/etsi/etsi_nfvo_ns_lcm_tests.robot b/tests/so/etsi/etsi_nfvo_ns_lcm_tests.robot
new file mode 100644
index 00000000..e931b3ca
--- /dev/null
+++ b/tests/so/etsi/etsi_nfvo_ns_lcm_tests.robot
@@ -0,0 +1,27 @@
+*** Settings ***
+Library Collections
+Library RequestsLibrary
+Library OperatingSystem
+Library json
+Library ArchiveLibrary
+
+*** Variables ***
+${NFVO_NS_LCM_BASE_URL}= /so/so-etsi-nfvo-ns-lcm/v1/api/nslcm/v1
+${BASIC_AUTH}= Basic c28tZXRzaS1uZnZvLW5zLWxjbTpwYXNzd29yZDEk
+
+*** Test Cases ***
+
+Invoke Create Network Service
+ Create Session etsi_nfvo_ns_lcm_session http://${REPO_IP}:9095
+ ${data}= Get Binary File ${CURDIR}${/}data${/}createNetworkServiceRequest.json
+ &{headers}= Create Dictionary Authorization=${BASIC_AUTH} Content-Type=application/json Accept=application/json HTTP_GLOBALCUSTOMERID=DemoCustomer
+ ${create_network_service_request}= POST On Session etsi_nfvo_ns_lcm_session ${NFVO_NS_LCM_BASE_URL}/ns_instances data=${data} headers=${headers}
+ log to console ${create_network_service_request.content}
+ ${create_network_service_json_response}= Evaluate json.loads(r"""${create_network_service_request.content}""", strict=False) json
+ ${request_Id}= Set Variable ${create_network_service_json_response}[id]
+ SET GLOBAL VARIABLE ${request_Id}
+
+ Run Keyword If '${create_network_service_request.status_code}' == '201' log to console \nexecuted with expected result
+ log to console \nCreate Network Service Response Status Code: ${create_network_service_request.status_code}
+ Should Be Equal As Strings '${create_network_service_request.status_code}' '201'
+