From 56c57cb713d0be956908b542db138fd0b7bf26b1 Mon Sep 17 00:00:00 2001 From: muhammadh Date: Wed, 15 Sep 2021 15:26:35 +0500 Subject: [PATCH 01/15] internal variables to ignore while building the HIVE-TAP GUI --- internal_variables.txt | 541 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 541 insertions(+) create mode 100644 internal_variables.txt diff --git a/internal_variables.txt b/internal_variables.txt new file mode 100644 index 000000000..51cafb784 --- /dev/null +++ b/internal_variables.txt @@ -0,0 +1,541 @@ +################################################################ +####################### v3.3.1-fix-plu ######################### +################################################################ + + +######################### SOL002 ############################### + + +### SOL002 VNFConfiguration-API ### + +${response}= httpresponse +${ACCEPT} application/json +${CONTENT_TYPE} application/json + +### SOL002 VNFFaultManagement-API ### + +${ACCEPT} application/json +${ACCEPT_JSON} application/json +${CONTENT_TYPE} application/json +${origResponse}= httpresponse +${CONTENT_TYPE_PATCH} application/merge-patch+json +${notification_request} [] +${notification_response} [] +${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +${AlarmNotification} {} +${AlarmClearedNotification} {} +${AlarmListRebuiltNotification} {} +#${response}= httpresponse + +### SOL002 VNFIndicator-API ### + +${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response} some_response_object +#${origResponse}= httpresponse +${vnfIndicators} = + +### SOL002 VNFIndicatorNotification-API ### + +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + +### SOL002 VNFLifecycleManagement-API ### + +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +${ACCEPT_PLAIN} text/plain +${ACCEPT_ZIP} application/zip +${ARTIFACT_TYPE} application/octet-stream +${WRONG_ACCEPT} application/json +${VnfLcmOperationOccurrenceNotification} {} +${VnfIdentifierCreationNotification} {} +${VnfIdentifierDeletionNotification} {} +#${notification_request} [] +#${notification_response} [] +#${response}= httpresponse +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + +${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute +${tosca_type_VNF} tosca.nodes.nfv.VNF +${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink +${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp +${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage + +@{VDU_IDs} +@{VNF_IDs} +@{virtualLink_IDs} +@{CP_IDs} +@{Storage_IDs} +@{internalCP_IDs} +@{externalCP_IDs} +@{InstantiationLevel_IDs} + +${Descriptor_ID} +${Provider} +${Product_Name} +${Software_Version} +${Descriptor_Version} + +${scaleVnfRequesttype} SCALE_OUT +${scaleVnfRequestAspect} Aspect + + +### SOL002 VNFPerformanceManagement-API ### + +#${CONTENT_TYPE_JSON} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response} http-response +${subscribe} /subscribe +${OrigResponse}= httpresponse + +### SOL002 VNFPerformanceManagementNotification-API ### + +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + + +######################### SOL003 ############################### + + +### SOL003 VirtualizedQuotaAvailableNotification-API ### + +#${CONTENT_TYPE} application/json +#${ACCEPT} application/json +#${notification_request} [] +#${notification_response} [] +${VrQuotaAvailNotification} {} +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response} {} + + +### SOL003 VNFFaultManagement-API ### + +#${CONTENT_TYPE} application/json +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${AlarmNotification} {} +#${AlarmClearedNotification} {} +#${AlarmListRebuiltNotification} {} +#${response} {} +${req_mock} {} +${resp_mock} {} +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + + +### SOL003 VNFFaultManagementNotification-API ### + +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + + +### SOL003 VNFIndicator-API ### + +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE_JSON} application/json +#${response} +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${origResponse} httpresponse + + +### SOL003 VNFLifecycleManagement-API ### + +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ARTIFACT_TYPE} application/octet-stream +#${WRONG_ACCEPT} application/json +${ACCEPT_OCTET} application/octet-stream + +${CONTENT_TYPE_OCTET} application/octet-stream +${VnfLcmOperationOccurrenceNotification} {} +${VnfIdentifierCreationNotification} {} +${VnfIdentifierDeletionNotification} {} +#${response} {} +${json} {} + +${changeVnfFlavourRequest} {} +${changeVnfOperateRequest} {} +${requestedState} test +${changeVnfExtConnectivityRequest} {} +${patchBodyRequest} {} + +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + +${LccnSubscriptions} +${scaleInfo} +${element} +${scaleOutResponse} + +#${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute +#${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink +#${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp + +#@{VDU_IDs} +#@{virtualLink_IDs} +#@{CP_IDs} +#@{externalCP_IDs} + +#${Descriptor_ID} +#${Provider} +#${Product_Name} +#${Software_Version} +#${Descriptor_Version} + + +### SOL003 VNFLifecycleOperationGranting-API ### + +#${CONTENT_TYPE} application/json +#${ACCEPT} application/json +#${response} {} +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ARTIFACT_TYPE} application/octet-stream +#${WRONG_ACCEPT} application/json +#${VrQuotaAvailNotification} {} + +#${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute +#${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink +#${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp + +#@{VDU_IDs} +#@{virtualLink_IDs} +#@{CP_IDs} +#@{externalCP_IDs} + +#${Descriptor_ID} +#${Provider} +#${Product_Name} +#${Software_Version} +#${Descriptor_Version} + + +### SOL003 VNFPackageManagement-API ### + +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE_JSON} application/json +#${response} httpresponse +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${notification_request} [] +#${notification_response} [] +#${origResponse} httpresponse +#${ACCEPT_PLAIN} text/plain +${CONTENT_TYPE_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +${CONTENT_TYPE_ZIP} application/zip +#${artifactPath} artifactPath +#${CONTENT_TYPE_OCTET} application/octet-stream + +#${Descriptor_ID} +#${Provider} +#${Product_Name} +#${Software_Version} +#${Descriptor_Version} + +### SOL003 VNFPerformanceManagement-API ### + + +#${CONTENT_TYPE_JSON} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response}= httpresponse +#${OrigResponse}= httpresponse +#${notification_request} [] +#${notification_response} [] + + +### SOL003 VNFSnapshotPackages-API ### + +#${ACCEPT_JSON} application/json +#${AUTH_USAGE} 1 +#${CONTENT_TYPE_JSON} application/json +#${response} httpresponse +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${notification_request} [] +#${notification_response} [] +#${origResponse} httpresponse +#${ACCEPT_PLAIN} text/plain +#${CONTENT_TYPE_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ACCEPT_OCTET} application/octet-stream +#${CONTENT_TYPE_ZIP} application/zip +#${CONTENT_TYPE_OCTET} application/octet-stream + + +######################### SOL005 ############################### + + +### SOL005 NFVICapacityInformation-API ### + +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE_JSON} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${response} httpresponse +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${notification_request} [] +#${notification_response} [] +#${origResponse} httpresponse +#${ACCEPT_PLAIN} text/plain +#${CONTENT_TYPE_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ACCEPT_OCTET} application/octet-stream +#${CONTENT_TYPE_ZIP} application/zip +#${CONTENT_TYPE_OCTET} application/octet-stream + + +### SOL005 NSDManagement-API ### + +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${notification_request} [] +#${notification_response} [] +#${response} httpresponse +#${origResponse} httpresponse +#${ACCEPT_ZIP} application/zip +#${ACCEPT_PLAIN} text/plain +#${CONTENT_TYPE_ZIP} application/zip +#${CONTENT_TYPE_PLAIN} text/plain +#${CONTENT_TYPE_OCTET} application/octet-stream + + +### SOL005 NSFaultManagement-API ### + +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${AlarmNotification} {} +#${AlarmClearedNotification} {} +#${AlarmListRebuiltNotification} {} +#${response} {} +#${req_mock} {} +#${resp_mock} {} +#${notification_request} [] +#${notification_response} [] + + +### SOL005 NSLifecycleManagement-API ### + +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_JSON} application/json +#${ACCEPT} application/json +#${ACCEPT_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ARTIFACT_TYPE} application/octet-stream +#${WRONG_ACCEPT} application/json +#${VnfLcmOperationOccurrenceNotification} {} +#${VnfIdentifierCreationNotification} {} +#${VnfIdentifierDeletionNotification} {} +#${notification_request} {} +#${notification_response} {} +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response} {} +#${json} {"notificationStatus": ""} + +#${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute +#${tosca_type_VNF} tst010.vnf.simple # custom tosca type defined in the descriptor vnfd_SOL001.yaml in descriptors folder +#${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink +#${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp +#${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage + +#@{VDU_IDs} +#@{VNF_IDs} +#@{virtualLink_IDs} +#@{CP_IDs} +#@{Storage_IDs} +#@{internalCP_IDs} +#@{externalCP_IDs} +#@{InstantiationLevel_IDs} + +#${Descriptor_ID} +#${Provider} +#${Product_Name} +#${Software_Version} +#${Descriptor_Version} + + +### SOL005 NSPerformanceManagement-API ### + +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + +#${response} {} +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${origResponse}= httpresponse +#${notification_request} [] +#${notification_response} [] + + +### SOL005 VNFPackageManagement-API ### + +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response} +#${notification_request} [] +#${notification_response} [] +#${origResponse} httpresponse +#${ACCEPT_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${CONTENT_TYPE_PLAIN} text/plain +#${CONTENT_TYPE_ZIP} application/zip +#${CONTENT_TYPE_OCTET} application/octet-stream + +#${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute +#${tosca_type_VNF} tosca.nodes.nfv.VNF +#${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink +#${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp +#${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage + +#@{VDU_IDs} +#@{VNF_IDs} +#@{virtualLink_IDs} +#@{CP_IDs} +#@{Storage_IDs} +#@{internalCP_IDs} +#@{externalCP_IDs} +#@{InstantiationLevel_IDs} + +#${Descriptor_ID} +#${Provider} +#${Product_Name} +#${Software_Version} +#${Descriptor_Version} + +### SOL005 VNFSnapshotPackageManagement-API ### + +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE_JSON} application/json +#${response} httpresponse +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${notification_request} [] +#${notification_response} [] +#${origResponse} httpresponse +#${ACCEPT_PLAIN} text/plain +#${CONTENT_TYPE_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ACCEPT_OCTET} application/octet-stream +#${CONTENT_TYPE_ZIP} application/zip +#${CONTENT_TYPE_OCTET} application/octet-stream + + +######################### SOL009 ############################### + +### SOL009 NFVManoConfigurationAndInformationManagement-API ### + +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${response} +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${origResponse} {} + + +### SOL009 NFVMANOFaultManagement-API ### + +#${CONTENT_TYPE} application/json +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +#${response} {} +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + + +### SOL009 NFVMANOLogManagement-API ### + +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${ACCEPT} application/json +#${response} {} +#${origResponse} {} +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + + +### SOL009 NFVMANOPerformanceManagement-API ### + +#${response}= httpresponse +#${OrigResponse}= httpresponse +#${notification_request} [] +#${notification_response} [] +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT_JSON} application/json +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar +#${response} + + +######################### SOL011 ############################### + + +### SOL011 NSInstanceUsageNotification-API ### + +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +#${response} {} +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ARTIFACT_TYPE} application/octet-stream +#${WRONG_ACCEPT} application/json +#${VrQuotaAvailNotification} {} +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar + +### SOL011 NSLifecycleOperationGranting-API ### + +#${CONTENT_TYPE} application/json +#${ACCEPT} application/json +#${response} +#${CONTENT_TYPE_PATCH} application/merge-patch+json +#${ACCEPT_PLAIN} text/plain +#${ACCEPT_ZIP} application/zip +#${ARTIFACT_TYPE} application/octet-stream +#${WRONG_ACCEPT} application/json +#${VrQuotaAvailNotification} {} + + +######################### SOL012 ############################### + + +### SOL012 PolicyManagement-API ### + +#${CONTENT_TYPE} application/json +#${CONTENT_TYPE_JSON} application/json +#${ACCEPT} application/json +#${ACCEPT_JSON} application/json +${POLICY_CONTENT_TYPE} application/json +#${response} {} +#${VrQuotaAvailNotification} {} +#${notification_request} [] +#${notification_response} [] +#${MOCK_SERVER_JAR} ../../../bin/mockserver-netty-5.5.0-jar-with-dependencies.jar \ No newline at end of file -- GitLab From 582b6ad681b9107832c357b1108f2cfd72846b54 Mon Sep 17 00:00:00 2001 From: muhammadh Date: Fri, 17 Sep 2021 15:18:16 +0500 Subject: [PATCH 02/15] changed the notation for list type environment/variables and internal variables --- .../environment/variables.txt | 16 ++--- .../environment/variables.txt | 16 ++--- .../environment/variables.txt | 10 +-- .../environment/variables.txt | 24 +++---- .../environment/variables.txt | 16 ++--- internal_variables.txt | 64 +++++++++---------- 6 files changed, 73 insertions(+), 73 deletions(-) diff --git a/SOL002/VNFLifecycleManagement-API/environment/variables.txt b/SOL002/VNFLifecycleManagement-API/environment/variables.txt index fb0bb2907..4c3960dbd 100644 --- a/SOL002/VNFLifecycleManagement-API/environment/variables.txt +++ b/SOL002/VNFLifecycleManagement-API/environment/variables.txt @@ -101,14 +101,14 @@ ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage -@{VDU_IDs} -@{VNF_IDs} -@{virtualLink_IDs} -@{CP_IDs} -@{Storage_IDs} -@{internalCP_IDs} -@{externalCP_IDs} -@{InstantiationLevel_IDs} +${VDU_IDs} +${VNF_IDs} +${virtualLink_IDs} +${CP_IDs} +${Storage_IDs} +${internalCP_IDs} +${externalCP_IDs} +${InstantiationLevel_IDs} ${Descriptor_ID} ${Provider} diff --git a/SOL003/VNFLifecycleManagement-API/environment/variables.txt b/SOL003/VNFLifecycleManagement-API/environment/variables.txt index 53851db2a..bb8e1657f 100644 --- a/SOL003/VNFLifecycleManagement-API/environment/variables.txt +++ b/SOL003/VNFLifecycleManagement-API/environment/variables.txt @@ -146,14 +146,14 @@ ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage -@{VDU_IDs} -@{VNF_IDs} -@{virtualLink_IDs} -@{CP_IDs} -@{Storage_IDs} -@{internalCP_IDs} -@{externalCP_IDs} -@{InstantiationLevel_IDs} +${VDU_IDs} +${VNF_IDs} +${virtualLink_IDs} +${CP_IDs} +${Storage_IDs} +${internalCP_IDs} +${externalCP_IDs} +${InstantiationLevel_IDs} ${Descriptor_ID} ${Provider} diff --git a/SOL003/VNFLifecycleOperationGranting-API/environment/variables.txt b/SOL003/VNFLifecycleOperationGranting-API/environment/variables.txt index dbbedb4bf..61ccb5695 100644 --- a/SOL003/VNFLifecycleOperationGranting-API/environment/variables.txt +++ b/SOL003/VNFLifecycleOperationGranting-API/environment/variables.txt @@ -51,11 +51,11 @@ ${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp -@{VDU_IDs} -@{virtualLink_IDs} -@{CP_IDs} -@{externalCP_IDs} -@{Compute_IDs} +${VDU_IDs} +${virtualLink_IDs} +${CP_IDs} +${externalCP_IDs} +${Compute_IDs} ${Descriptor_ID} ${Provider} diff --git a/SOL005/NSLifecycleManagement-API/environment/variables.txt b/SOL005/NSLifecycleManagement-API/environment/variables.txt index 5576d1622..ca2f36fe8 100644 --- a/SOL005/NSLifecycleManagement-API/environment/variables.txt +++ b/SOL005/NSLifecycleManagement-API/environment/variables.txt @@ -111,18 +111,18 @@ ${tosca_type_NS} tosca.nodes.nfv.NS ${tosca_type_NsVirtualLink} tosca.nodes.nfv.NsVirtualLink ${tosca_type_NsCP} tosca.nodes.nfv.Cp -@{VDU_IDs} -@{VNF_IDs} -@{virtualLink_IDs} -@{CP_IDs} -@{Storage_IDs} -@{internalCP_IDs} -@{externalCP_IDs} -@{InstantiationLevel_IDs} - -@{NS_VirtualLink_IDs} -@{NsCP_IDs} -@{SAP_IDs} +${VDU_IDs} +${VNF_IDs} +${virtualLink_IDs} +${CP_IDs} +${Storage_IDs} +${internalCP_IDs} +${externalCP_IDs} +${InstantiationLevel_IDs} + +${NS_VirtualLink_IDs} +${NsCP_IDs} +${SAP_IDs} ${NS_DescriptorID} ${Designer} diff --git a/SOL005/VNFPackageManagement-API/environment/variables.txt b/SOL005/VNFPackageManagement-API/environment/variables.txt index 8846ff677..af33fce8c 100644 --- a/SOL005/VNFPackageManagement-API/environment/variables.txt +++ b/SOL005/VNFPackageManagement-API/environment/variables.txt @@ -99,14 +99,14 @@ ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage -@{VDU_IDs} -@{VNF_IDs} -@{virtualLink_IDs} -@{CP_IDs} -@{Storage_IDs} -@{internalCP_IDs} -@{externalCP_IDs} -@{InstantiationLevel_IDs} +${VDU_IDs} +${VNF_IDs} +${virtualLink_IDs} +${CP_IDs} +${Storage_IDs} +${internalCP_IDs} +${externalCP_IDs} +${InstantiationLevel_IDs} ${Descriptor_ID} ${Provider} diff --git a/internal_variables.txt b/internal_variables.txt index 51cafb784..89817045f 100644 --- a/internal_variables.txt +++ b/internal_variables.txt @@ -66,14 +66,14 @@ ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage -@{VDU_IDs} -@{VNF_IDs} -@{virtualLink_IDs} -@{CP_IDs} -@{Storage_IDs} -@{internalCP_IDs} -@{externalCP_IDs} -@{InstantiationLevel_IDs} +${VDU_IDs} +${VNF_IDs} +${virtualLink_IDs} +${CP_IDs} +${Storage_IDs} +${internalCP_IDs} +${externalCP_IDs} +${InstantiationLevel_IDs} ${Descriptor_ID} ${Provider} @@ -187,10 +187,10 @@ ${scaleOutResponse} #${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink #${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp -#@{VDU_IDs} -#@{virtualLink_IDs} -#@{CP_IDs} -#@{externalCP_IDs} +#${VDU_IDs} +#${virtualLink_IDs} +#${CP_IDs} +#${externalCP_IDs} #${Descriptor_ID} #${Provider} @@ -215,10 +215,10 @@ ${scaleOutResponse} #${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink #${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp -#@{VDU_IDs} -#@{virtualLink_IDs} -#@{CP_IDs} -#@{externalCP_IDs} +#${VDU_IDs} +#${virtualLink_IDs} +#${CP_IDs} +#${externalCP_IDs} #${Descriptor_ID} #${Provider} @@ -358,14 +358,14 @@ ${CONTENT_TYPE_ZIP} application/zip #${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp #${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage -#@{VDU_IDs} -#@{VNF_IDs} -#@{virtualLink_IDs} -#@{CP_IDs} -#@{Storage_IDs} -#@{internalCP_IDs} -#@{externalCP_IDs} -#@{InstantiationLevel_IDs} +#${VDU_IDs} +#${VNF_IDs} +#${virtualLink_IDs} +#${CP_IDs} +#${Storage_IDs} +#${internalCP_IDs} +#${externalCP_IDs} +#${InstantiationLevel_IDs} #${Descriptor_ID} #${Provider} @@ -408,14 +408,14 @@ ${CONTENT_TYPE_ZIP} application/zip #${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp #${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage -#@{VDU_IDs} -#@{VNF_IDs} -#@{virtualLink_IDs} -#@{CP_IDs} -#@{Storage_IDs} -#@{internalCP_IDs} -#@{externalCP_IDs} -#@{InstantiationLevel_IDs} +#${VDU_IDs} +#${VNF_IDs} +#${virtualLink_IDs} +#${CP_IDs} +#${Storage_IDs} +#${internalCP_IDs} +#${externalCP_IDs} +#${InstantiationLevel_IDs} #${Descriptor_ID} #${Provider} -- GitLab From fd70870c839a4943153b480610bd3721653a6341 Mon Sep 17 00:00:00 2001 From: hammad zafar Date: Mon, 20 Sep 2021 11:58:56 +0500 Subject: [PATCH 03/15] added some missing internal variables to be removed from TAP GUI --- internal_variables.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/internal_variables.txt b/internal_variables.txt index 89817045f..5890a71c9 100644 --- a/internal_variables.txt +++ b/internal_variables.txt @@ -316,6 +316,12 @@ ${CONTENT_TYPE_ZIP} application/zip #${CONTENT_TYPE_PLAIN} text/plain #${CONTENT_TYPE_OCTET} application/octet-stream +${NS_DescriptorID} +${Designer} +${NS_Name} +${NS_Version} +${NS_InvariantId} + ### SOL005 NSFaultManagement-API ### @@ -373,6 +379,12 @@ ${CONTENT_TYPE_ZIP} application/zip #${Software_Version} #${Descriptor_Version} +#${NS_DescriptorID} +#${Designer} +#${NS_Name} +#${NS_Version} +#${NS_InvariantId} + ### SOL005 NSPerformanceManagement-API ### -- GitLab From e26b745a40da90629b06536df1d70d5974e80bf9 Mon Sep 17 00:00:00 2001 From: Giacomo Bernini Date: Tue, 21 Sep 2021 18:28:55 +0200 Subject: [PATCH 04/15] fixed issues #90 and #190 in 3.3.1 --- SOL002/VNFConfiguration-API/Configuration.robot | 3 ++- SOL002/VNFFaultManagement-API/Alarms.robot | 3 ++- SOL002/VNFFaultManagement-API/IndividualAlarm.robot | 3 ++- SOL002/VNFFaultManagement-API/IndividualSubscription.robot | 3 ++- SOL002/VNFFaultManagement-API/Subscriptions.robot | 3 ++- SOL002/VNFIndicator-API/IndividualSubscription.robot | 3 ++- SOL002/VNFIndicator-API/IndividualVNFindicator.robot | 3 ++- SOL002/VNFIndicator-API/Subscriptions.robot | 3 ++- SOL002/VNFIndicator-API/VNFIndicators.robot | 3 ++- SOL002/VNFIndicator-API/VnfIndicatorsInVnfInstanceId.robot | 3 ++- .../VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot | 2 ++ SOL002/VNFPerformanceManagement-API/IndividualPmJob.robot | 3 ++- SOL002/VNFPerformanceManagement-API/IndividualReport.robot | 3 ++- SOL002/VNFPerformanceManagement-API/IndividualThreshold.robot | 3 ++- SOL002/VNFPerformanceManagement-API/PMJobs.robot | 3 ++- SOL002/VNFPerformanceManagement-API/Thresholds.robot | 3 ++- .../VNFPerformanceManagementKeywords.robot | 3 ++- SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot | 2 ++ SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot | 3 ++- .../VnfLcmMntOperationKeywords.robot | 2 ++ SOL003/VNFLifecycleOperationGranting-API/Grants.robot | 2 ++ SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot | 2 ++ .../VNFPackageManagementKeywords.robot | 3 ++- SOL003/VNFPerformanceManagement-API/IndividualPmJob.robot | 3 ++- SOL003/VNFPerformanceManagement-API/IndividualReport.robot | 3 ++- SOL003/VNFPerformanceManagement-API/IndividualThreshold.robot | 3 ++- SOL003/VNFPerformanceManagement-API/PMJobs.robot | 3 ++- SOL003/VNFPerformanceManagement-API/Thresholds.robot | 3 ++- .../VnfSnapshotPackageManagementKeywords.robot | 2 ++ .../VRQANOperationKeywords.robot | 2 ++ .../NFVICapacityInformationKeywords.robot | 2 ++ SOL005/NSDManagement-API/NSDManagementKeywords.robot | 3 ++- SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot | 2 ++ SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot | 2 ++ .../NSPerformanceManagementKeywords.robot | 3 ++- .../VNFPackageManagementKeywords.robot | 3 ++- .../VnfSnapshotPackageManagementKeywords.robot | 2 ++ .../FaultManagement-APIKeyword.robot | 2 ++ .../NFVMANOLogManagementKeywords.robot | 3 ++- SOL009/NFVMANOPerformanceManagement-API/IndividualPmJob.robot | 3 ++- SOL009/NFVMANOPerformanceManagement-API/IndividualReport.robot | 3 ++- .../IndividualSubscription.robot | 3 ++- .../NFVMANOPerformanceManagement-API/IndividualThreshold.robot | 3 ++- SOL009/NFVMANOPerformanceManagement-API/PMJobs.robot | 3 ++- SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot | 3 ++- SOL009/NFVMANOPerformanceManagement-API/Thresholds.robot | 3 ++- .../NFVMANOCimKeywords.robot | 3 ++- .../NSInstanceUsageNotificationKeywords.robot | 2 ++ .../NSLCOperationGrantingKeywords.robot | 2 ++ SOL012/PolicyManagement-API/PolicyManagementKeywords.robot | 2 ++ 50 files changed, 100 insertions(+), 35 deletions(-) diff --git a/SOL002/VNFConfiguration-API/Configuration.robot b/SOL002/VNFConfiguration-API/Configuration.robot index e73d7b725..870974463 100644 --- a/SOL002/VNFConfiguration-API/Configuration.robot +++ b/SOL002/VNFConfiguration-API/Configuration.robot @@ -136,7 +136,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/problem+json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema}= Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFFaultManagement-API/Alarms.robot b/SOL002/VNFFaultManagement-API/Alarms.robot index 38cda3c6b..799660219 100644 --- a/SOL002/VNFFaultManagement-API/Alarms.robot +++ b/SOL002/VNFFaultManagement-API/Alarms.robot @@ -352,7 +352,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFFaultManagement-API/IndividualAlarm.robot b/SOL002/VNFFaultManagement-API/IndividualAlarm.robot index 84bf414a5..84e3acec7 100644 --- a/SOL002/VNFFaultManagement-API/IndividualAlarm.robot +++ b/SOL002/VNFFaultManagement-API/IndividualAlarm.robot @@ -191,7 +191,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFFaultManagement-API/IndividualSubscription.robot b/SOL002/VNFFaultManagement-API/IndividualSubscription.robot index bb36528d0..e390d767c 100644 --- a/SOL002/VNFFaultManagement-API/IndividualSubscription.robot +++ b/SOL002/VNFFaultManagement-API/IndividualSubscription.robot @@ -147,7 +147,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFFaultManagement-API/Subscriptions.robot b/SOL002/VNFFaultManagement-API/Subscriptions.robot index 9277b7d58..9e6d937f2 100644 --- a/SOL002/VNFFaultManagement-API/Subscriptions.robot +++ b/SOL002/VNFFaultManagement-API/Subscriptions.robot @@ -427,7 +427,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFIndicator-API/IndividualSubscription.robot b/SOL002/VNFIndicator-API/IndividualSubscription.robot index 4281108b3..ea2a8d777 100644 --- a/SOL002/VNFIndicator-API/IndividualSubscription.robot +++ b/SOL002/VNFIndicator-API/IndividualSubscription.robot @@ -168,7 +168,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFIndicator-API/IndividualVNFindicator.robot b/SOL002/VNFIndicator-API/IndividualVNFindicator.robot index 3a6ce0935..037704350 100644 --- a/SOL002/VNFIndicator-API/IndividualVNFindicator.robot +++ b/SOL002/VNFIndicator-API/IndividualVNFindicator.robot @@ -218,7 +218,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFIndicator-API/Subscriptions.robot b/SOL002/VNFIndicator-API/Subscriptions.robot index 481813f72..ba59c8166 100644 --- a/SOL002/VNFIndicator-API/Subscriptions.robot +++ b/SOL002/VNFIndicator-API/Subscriptions.robot @@ -282,7 +282,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFIndicator-API/VNFIndicators.robot b/SOL002/VNFIndicator-API/VNFIndicators.robot index 36b0d5309..0a53a03b2 100644 --- a/SOL002/VNFIndicator-API/VNFIndicators.robot +++ b/SOL002/VNFIndicator-API/VNFIndicators.robot @@ -286,7 +286,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${schema} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${jsonSchema}= Catenate SEPARATOR= ${schema} .schema.json Validate Json ${jsonSchema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFIndicator-API/VnfIndicatorsInVnfInstanceId.robot b/SOL002/VNFIndicator-API/VnfIndicatorsInVnfInstanceId.robot index 5f98314bf..751f102fc 100644 --- a/SOL002/VNFIndicator-API/VnfIndicatorsInVnfInstanceId.robot +++ b/SOL002/VNFIndicator-API/VnfIndicatorsInVnfInstanceId.robot @@ -214,7 +214,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot b/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot index 5568a8b60..9a9fb2659 100644 --- a/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot +++ b/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot @@ -44,6 +44,8 @@ Check HTTP Location Header Contains URI of Created Resource Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFPerformanceManagement-API/IndividualPmJob.robot b/SOL002/VNFPerformanceManagement-API/IndividualPmJob.robot index 32440446f..9efe99998 100644 --- a/SOL002/VNFPerformanceManagement-API/IndividualPmJob.robot +++ b/SOL002/VNFPerformanceManagement-API/IndividualPmJob.robot @@ -229,7 +229,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFPerformanceManagement-API/IndividualReport.robot b/SOL002/VNFPerformanceManagement-API/IndividualReport.robot index c441161df..fbaf31ae6 100644 --- a/SOL002/VNFPerformanceManagement-API/IndividualReport.robot +++ b/SOL002/VNFPerformanceManagement-API/IndividualReport.robot @@ -155,7 +155,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFPerformanceManagement-API/IndividualThreshold.robot b/SOL002/VNFPerformanceManagement-API/IndividualThreshold.robot index b89cfb101..3b1ede734 100644 --- a/SOL002/VNFPerformanceManagement-API/IndividualThreshold.robot +++ b/SOL002/VNFPerformanceManagement-API/IndividualThreshold.robot @@ -228,7 +228,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFPerformanceManagement-API/PMJobs.robot b/SOL002/VNFPerformanceManagement-API/PMJobs.robot index 6729e776e..8de51eb61 100644 --- a/SOL002/VNFPerformanceManagement-API/PMJobs.robot +++ b/SOL002/VNFPerformanceManagement-API/PMJobs.robot @@ -409,7 +409,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFPerformanceManagement-API/Thresholds.robot b/SOL002/VNFPerformanceManagement-API/Thresholds.robot index 63cc80724..9f9c31401 100644 --- a/SOL002/VNFPerformanceManagement-API/Thresholds.robot +++ b/SOL002/VNFPerformanceManagement-API/Thresholds.robot @@ -258,7 +258,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot b/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot index a5e14818d..f986bff12 100644 --- a/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot +++ b/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot @@ -271,7 +271,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot b/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot index 72dce684a..896533beb 100644 --- a/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot +++ b/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot @@ -63,6 +63,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot b/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot index eb7e4d107..adadcbcc8 100644 --- a/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot +++ b/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot @@ -168,7 +168,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot index 7949f59da..7cfc01879 100644 --- a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot +++ b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot @@ -42,6 +42,8 @@ Check Operation Occurrence Id existence Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFLifecycleOperationGranting-API/Grants.robot b/SOL003/VNFLifecycleOperationGranting-API/Grants.robot index 09cc71681..d404f521b 100644 --- a/SOL003/VNFLifecycleOperationGranting-API/Grants.robot +++ b/SOL003/VNFLifecycleOperationGranting-API/Grants.robot @@ -165,6 +165,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} diff --git a/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot b/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot index 5f78fe347..f018e15ca 100644 --- a/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot +++ b/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot @@ -162,6 +162,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} diff --git a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index 244baea75..e7a7b117a 100644 --- a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -648,7 +648,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFPerformanceManagement-API/IndividualPmJob.robot b/SOL003/VNFPerformanceManagement-API/IndividualPmJob.robot index 8e672dda5..bda65d8b1 100644 --- a/SOL003/VNFPerformanceManagement-API/IndividualPmJob.robot +++ b/SOL003/VNFPerformanceManagement-API/IndividualPmJob.robot @@ -250,7 +250,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFPerformanceManagement-API/IndividualReport.robot b/SOL003/VNFPerformanceManagement-API/IndividualReport.robot index 913685180..f75b0d0f4 100644 --- a/SOL003/VNFPerformanceManagement-API/IndividualReport.robot +++ b/SOL003/VNFPerformanceManagement-API/IndividualReport.robot @@ -144,7 +144,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFPerformanceManagement-API/IndividualThreshold.robot b/SOL003/VNFPerformanceManagement-API/IndividualThreshold.robot index ccfbc2cc8..c991eb863 100644 --- a/SOL003/VNFPerformanceManagement-API/IndividualThreshold.robot +++ b/SOL003/VNFPerformanceManagement-API/IndividualThreshold.robot @@ -239,7 +239,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFPerformanceManagement-API/PMJobs.robot b/SOL003/VNFPerformanceManagement-API/PMJobs.robot index 62f90e043..49c284c4c 100644 --- a/SOL003/VNFPerformanceManagement-API/PMJobs.robot +++ b/SOL003/VNFPerformanceManagement-API/PMJobs.robot @@ -445,7 +445,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFPerformanceManagement-API/Thresholds.robot b/SOL003/VNFPerformanceManagement-API/Thresholds.robot index 191540a1d..230ae2300 100644 --- a/SOL003/VNFPerformanceManagement-API/Thresholds.robot +++ b/SOL003/VNFPerformanceManagement-API/Thresholds.robot @@ -262,7 +262,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index 0a68e1451..b45a9f84c 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -84,6 +84,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot b/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot index 82d28996e..0e98e5e17 100644 --- a/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot +++ b/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot @@ -34,6 +34,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL005/NFVICapacityInformation-API/NFVICapacityInformationKeywords.robot b/SOL005/NFVICapacityInformation-API/NFVICapacityInformationKeywords.robot index 1efc69be4..d4ce40ea1 100644 --- a/SOL005/NFVICapacityInformation-API/NFVICapacityInformationKeywords.robot +++ b/SOL005/NFVICapacityInformation-API/NFVICapacityInformationKeywords.robot @@ -86,6 +86,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL005/NSDManagement-API/NSDManagementKeywords.robot b/SOL005/NSDManagement-API/NSDManagementKeywords.robot index fa450c157..1f7d141ef 100644 --- a/SOL005/NSDManagement-API/NSDManagementKeywords.robot +++ b/SOL005/NSDManagement-API/NSDManagementKeywords.robot @@ -853,7 +853,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Log ${response['body']} Validate Json ${schema} ${response['body']} diff --git a/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot b/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot index 8584aaec2..be49a99aa 100644 --- a/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot +++ b/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot @@ -35,6 +35,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot b/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot index bbde72695..446f6ba0f 100644 --- a/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot +++ b/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot @@ -198,6 +198,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL005/NSPerformanceManagement-API/NSPerformanceManagementKeywords.robot b/SOL005/NSPerformanceManagement-API/NSPerformanceManagementKeywords.robot index 8c566c0d4..69f8826c5 100644 --- a/SOL005/NSPerformanceManagement-API/NSPerformanceManagementKeywords.robot +++ b/SOL005/NSPerformanceManagement-API/NSPerformanceManagementKeywords.robot @@ -556,7 +556,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index 9cd205605..5a858d074 100644 --- a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -921,7 +921,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index 165ffc5bb..90349731f 100644 --- a/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -87,6 +87,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot b/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot index a83c15dd4..7b776100f 100644 --- a/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot +++ b/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot @@ -39,6 +39,8 @@ GET Fault Management Alarms Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate ${input} .schema.json Validate Json ${schema} ${response[0]['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot b/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot index f1ea06205..cb971a90d 100644 --- a/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot +++ b/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot @@ -24,7 +24,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/IndividualPmJob.robot b/SOL009/NFVMANOPerformanceManagement-API/IndividualPmJob.robot index 7b7b2564e..fb16841cf 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/IndividualPmJob.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/IndividualPmJob.robot @@ -177,7 +177,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/IndividualReport.robot b/SOL009/NFVMANOPerformanceManagement-API/IndividualReport.robot index b11f802b7..873fa6f4f 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/IndividualReport.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/IndividualReport.robot @@ -143,7 +143,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/IndividualSubscription.robot b/SOL009/NFVMANOPerformanceManagement-API/IndividualSubscription.robot index 0092c466b..2e0558a51 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/IndividualSubscription.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/IndividualSubscription.robot @@ -102,7 +102,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/IndividualThreshold.robot b/SOL009/NFVMANOPerformanceManagement-API/IndividualThreshold.robot index 1e8c9a94e..d66a5f555 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/IndividualThreshold.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/IndividualThreshold.robot @@ -177,7 +177,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/PMJobs.robot b/SOL009/NFVMANOPerformanceManagement-API/PMJobs.robot index f9be6fcb0..66281f44c 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/PMJobs.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/PMJobs.robot @@ -403,7 +403,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot b/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot index c3ae8e0db..e1185af35 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot @@ -204,7 +204,8 @@ Check HTTP Response Header Contains Link Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVMANOPerformanceManagement-API/Thresholds.robot b/SOL009/NFVMANOPerformanceManagement-API/Thresholds.robot index a96ea74c2..71a956bf4 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/Thresholds.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/Thresholds.robot @@ -213,7 +213,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot b/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot index 0689396c5..5657f95cb 100644 --- a/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot +++ b/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot @@ -24,7 +24,8 @@ Check HTTP Response Header Contains Check HTTP Response Body Json Schema Is [Arguments] ${input} - Should Contain ${response['headers']['Content-Type']} application/json + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate SEPARATOR= ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK diff --git a/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot b/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot index dd6194450..b72d95c96 100644 --- a/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot +++ b/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot @@ -35,6 +35,8 @@ Check HTTP Response Header Contains Link Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate ${input} .schema.json Validate Json ${schema} ${response['body']} diff --git a/SOL011/NSLifecycleOperationGranting-API/NSLCOperationGrantingKeywords.robot b/SOL011/NSLifecycleOperationGranting-API/NSLCOperationGrantingKeywords.robot index 9d29ab9d9..9838b930b 100644 --- a/SOL011/NSLifecycleOperationGranting-API/NSLCOperationGrantingKeywords.robot +++ b/SOL011/NSLifecycleOperationGranting-API/NSLCOperationGrantingKeywords.robot @@ -43,6 +43,8 @@ Check Resource URI existence Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate ${input} .schema.json Validate Json ${schema} ${response['body']} diff --git a/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot b/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot index 2de04c799..3f760a7d8 100644 --- a/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot +++ b/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot @@ -91,6 +91,8 @@ Check HTTP Response Status Code Is Check HTTP Response Body Json Schema Is [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json ${schema} = Catenate ${input} .schema.json Validate Json ${schema} ${response['body']} Log Json Schema Validation OK -- GitLab From d60ff1cc2f2f270c61856634082f45e52d4a3a04 Mon Sep 17 00:00:00 2001 From: Elian Kraja Date: Wed, 22 Sep 2021 17:23:11 +0200 Subject: [PATCH 05/15] Fix issue #153 --- .../VnfLcmMntOperationKeywords.robot | 8 +++++--- .../VNFPackageManagementKeywords.robot | 15 ++++++++++++++- .../VnfSnapshotPackageManagementKeywords.robot | 4 ++++ .../NSDManagement-API/NSDManagementKeywords.robot | 8 ++++++++ .../VNFPackageManagementKeywords.robot | 7 +++++++ .../VnfSnapshotPackageManagementKeywords.robot | 6 +++++- requirements.txt | 4 ++-- scripts/docker/Dockerfile | 2 +- 8 files changed, 46 insertions(+), 8 deletions(-) diff --git a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot index 7cfc01879..82d820f54 100644 --- a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot +++ b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot @@ -2071,8 +2071,9 @@ GET VNF State Snapshot - Range Request Set Headers {"Range":"${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshots/${vnfSnapshotInfoId}/vnf_state_snapshot + Unset Headers ["Range"] ${outputResponse}= Output response - Set Global Variable ${response} ${outputResponse} + Set Global Variable ${response} ${outputResponse} GET VNF State Snapshot - Invalid Range Pass Execution If ${VNFM_RANGE_OK} == 0 Skipping this test as NFVO is not able to handle partial Requests. @@ -2081,8 +2082,9 @@ GET VNF State Snapshot - Invalid Range Set Headers {"Range":"${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshots/${vnfSnapshotInfoId}/vnf_state_snapshot + Unset Headers ["Range"] ${outputResponse}= Output response - Set Global Variable ${response} ${outputResponse} + Set Global Variable ${response} ${outputResponse} GET VNF State Snapshot - Conflict in State Log Trying to get information about a VNF State Snapshot whose creation process is not completed @@ -2134,4 +2136,4 @@ Check HTTP Content-Length Header Is Set Log Check Content-Range HTTP Header Should Contain ${response['headers']} Content-Length Should Be Equal As Strings ${response['headers']['Content-Length']} ${full_length} - Log Header Content-Length is present \ No newline at end of file + Log Header Content-Length is present diff --git a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index e7a7b117a..0e268af7b 100644 --- a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -279,6 +279,7 @@ GET Individual VNF Package Content with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -288,6 +289,7 @@ GET Individual VNF Package Content with explicit Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -311,6 +313,7 @@ GET Individual VNF Package Content with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -581,6 +584,7 @@ GET Individual VNF Package Artifact with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -591,6 +595,7 @@ GET Individual VNF Package Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1054,6 +1059,7 @@ GET Individual OnBoarded VNF Package Content with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/onboarded_vnf_packages/${vndId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1064,6 +1070,7 @@ GET Individual OnBoarded VNF Package Content with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/onboarded_vnf_packages/${vndId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1103,6 +1110,7 @@ GET Individual OnBoarded VNF Package Artifact with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/onboarded_vnf_packages/${vndId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1113,6 +1121,7 @@ GET Individual OnBoarded VNF Package Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/onboarded_vnf_packages/${vndId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1397,6 +1406,7 @@ Get Artifact in VNF Package with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1430,6 +1440,7 @@ GET VNF Package Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1520,6 +1531,7 @@ Get Artifact in OnBoarded VNF Package with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/onboarded_vnf_packages/${vnfPackageId}/artifacts + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1553,6 +1565,7 @@ GET OnBoarded VNF Package Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} GET ${apiRoot}/${apiName}/${apiMajorVersion}/onboarded_vnf_packages/${vnfPackageId}/artifacts + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1661,4 +1674,4 @@ Match the VNF subscription Response Attributes with Descriptors Should Be Equal As Strings ${response['body']['filter']['vnfProductsFromProviders'][0]['vnfProducts'][0]['vnfProductName']} ${Product_Name} Should Be Equal As Strings ${response['body']['filter']['vnfProductsFromProviders'][0]['vnfProducts']['versions'][0]['vnfSoftwareVersion']} ${Software_Version} Should Be Equal As Strings ${response['body']['filter']['vnfProductsFromProviders'][0]['vnfProducts']['versions'][0]['vnfdVersion']} ${Descriptor_Version} - \ No newline at end of file + diff --git a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index b45a9f84c..cc739c3af 100644 --- a/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL003/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -285,6 +285,7 @@ GET VNF Snapshot Package Content - Range Request Set Headers {"Range":"${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -295,6 +296,7 @@ GET VNF Snapshot Package Content - Invalid Range Set Headers {"Range":"${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -374,6 +376,7 @@ GET Individual VNF Snapshot Package Artifact - Range Request Set Headers {"Range":"${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -384,6 +387,7 @@ GET Individual VNF Snapshot Package Artifact - Invalid Range Set Headers {"Range":"${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} diff --git a/SOL005/NSDManagement-API/NSDManagementKeywords.robot b/SOL005/NSDManagement-API/NSDManagementKeywords.robot index 1f7d141ef..3e3fd76b3 100644 --- a/SOL005/NSDManagement-API/NSDManagementKeywords.robot +++ b/SOL005/NSDManagement-API/NSDManagementKeywords.robot @@ -346,6 +346,7 @@ GET NSD Content with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/ns_descriptors/${nsdInfoIdZip}/nsd_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -356,6 +357,7 @@ GET NSD Content with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/ns_descriptors/${nsdInfoIdZip}/nsd_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -658,6 +660,7 @@ Get PNFD Content with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/pnf_descriptors/${pnfdInfoId}/pnfd_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -667,6 +670,7 @@ Get PNFD Content with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/pnf_descriptors/${pnfdInfoId}/pnfd_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1379,6 +1383,7 @@ GET Individual PNFD Archive Artifact with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/pnf_descriptors/${pnfdInfoId}/artifacts/${pnfd_artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1411,6 +1416,7 @@ GET Individual PNFD Archive Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/pnf_descriptors/${pnfdInfoId}/artifacts/${pnfd_artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1450,6 +1456,7 @@ GET Individual NSD Archive Artifact with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/ns_descriptors/${nsdInfoId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1494,6 +1501,7 @@ GET Individual NSD Archive Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/ns_descriptors/${nsdInfoId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} diff --git a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index 5a858d074..e4661c100 100644 --- a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -457,6 +457,7 @@ GET Individual VNF Package Content with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -466,6 +467,7 @@ GET Individual VNF Package Content with explicit Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -489,6 +491,7 @@ GET Individual VNF Package Content with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/package_content + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -586,6 +589,7 @@ GET Individual VNF Package Artifact with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -596,6 +600,7 @@ GET Individual VNF Package Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1133,6 +1138,7 @@ Get Artifact in VNF Package with Range Request Set Headers {"Range": "${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} @@ -1166,6 +1172,7 @@ GET VNF Package Artifact with invalid Range Request Set Headers {"Range": "${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} REST.GET ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_packages/${vnfPackageId}/artifacts + Unset Headers ["Range"] ${output}= Output response Set Suite Variable ${response} ${output} diff --git a/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot b/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot index 90349731f..e5c9cf02e 100644 --- a/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot +++ b/SOL005/VNFSnapshotPackageManagement-API/VnfSnapshotPackageManagementKeywords.robot @@ -324,6 +324,7 @@ GET VNF Snapshot Package Content - Range Request Set Headers {"Range":"${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -334,6 +335,7 @@ GET VNF Snapshot Package Content - Invalid Range Set Headers {"Range":"${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/package_content + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -438,6 +440,7 @@ GET Individual VNF Snapshot Package Artifact - Range Request Set Headers {"Range":"${range}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -448,6 +451,7 @@ GET Individual VNF Snapshot Package Artifact - Invalid Range Set Headers {"Range":"${erroneousRange}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/artifacts/${artifactPath} + Unset Headers ["Range"] ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -825,4 +829,4 @@ DELETE Access Configuration for External Artifacts Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_snapshot_packages/${vnfSnapshotPkgId}/ext_artifacts_access ${outputResponse}= Output response - Set Global Variable ${response} ${outputResponse} \ No newline at end of file + Set Global Variable ${response} ${outputResponse} diff --git a/requirements.txt b/requirements.txt index bafc102d3..4f00299b7 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,9 +1,9 @@ ## To install the libraries, use: # pip -r requirements.txt - +git+https://github.com/etsi-cti-admin/RESTinstance robotframework==3.1 -RESTinstance==1.0.0rc4 +#RESTinstance==1.0.0rc4 robotframework-dependencylibrary==1.0.0.post1 robotframework-jsonlibrary==0.3 robotframework-jsonschemalibrary==1.0 diff --git a/scripts/docker/Dockerfile b/scripts/docker/Dockerfile index bf5f18016..9f082157b 100644 --- a/scripts/docker/Dockerfile +++ b/scripts/docker/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:16.04 +FROM ubuntu:18.04 MAINTAINER ETSI STF 583 -- GitLab From 16f03de8332c36a619ab4e1bc8c728651ded875b Mon Sep 17 00:00:00 2001 From: Elian Kraja Date: Wed, 22 Sep 2021 17:47:40 +0200 Subject: [PATCH 06/15] CI/CD enhancements --- .jenkins.sh | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.jenkins.sh b/.jenkins.sh index 22ed7fcf2..8bfd08f3e 100644 --- a/.jenkins.sh +++ b/.jenkins.sh @@ -12,7 +12,18 @@ run_dir="$(pwd)" echo "Using git branch $GIT_BRANCH" bash ./scripts/build-container.sh -bash ./scripts/run-container.sh "${run_dir}" "$GIT_BRANCH" +ret=$? +if [ "$ret" != "0" ]; then + echo "build-container.sh failed" + exit -1 +fi + +bash ./scripts/run-container.sh "${run_dir}" +ret=$? +if [ "$ret" != "0" ]; then + echo "run-container.sh failed" + exit -1 +fi if [[ "$GIT_BRANCH" =~ .*fix-plu$ ]]; then @@ -30,3 +41,4 @@ fi ret=$? echo "Final validation result: $ret" exit $ret + -- GitLab From 651162ee4a936551ecaf233b98c1ae417e8bcbf0 Mon Sep 17 00:00:00 2001 From: Giacomo Bernini Date: Mon, 27 Sep 2021 10:21:05 +0200 Subject: [PATCH 07/15] fixed issue #191 in 3.3.1-fix-plu --- SOL005/NSFaultManagement-API/schemas/alarm.schema.json | 5 ++++- SOL005/NSFaultManagement-API/schemas/alarms.schema.json | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/SOL005/NSFaultManagement-API/schemas/alarm.schema.json b/SOL005/NSFaultManagement-API/schemas/alarm.schema.json index 76fc39504..5aadd14cd 100644 --- a/SOL005/NSFaultManagement-API/schemas/alarm.schema.json +++ b/SOL005/NSFaultManagement-API/schemas/alarm.schema.json @@ -157,7 +157,10 @@ }, "faultDetails": { "description": "Provides additional information about the fault..\n", - "type": "string" + "type": "array", + "items": { + "type": "string" + } }, "_links": { "description": "Links for this resource.\n", diff --git a/SOL005/NSFaultManagement-API/schemas/alarms.schema.json b/SOL005/NSFaultManagement-API/schemas/alarms.schema.json index 716025e57..b43c87fb1 100644 --- a/SOL005/NSFaultManagement-API/schemas/alarms.schema.json +++ b/SOL005/NSFaultManagement-API/schemas/alarms.schema.json @@ -159,7 +159,10 @@ }, "faultDetails": { "description": "Provides additional information about the fault..\n", - "type": "string" + "type": "array", + "items": { + "type": "string" + } }, "_links": { "description": "Links for this resource.\n", -- GitLab From e78bc6a4fb5e0f6ba1cb80f318e89aab1998c7d7 Mon Sep 17 00:00:00 2001 From: Giacomo Bernini Date: Mon, 27 Sep 2021 10:36:23 +0200 Subject: [PATCH 08/15] fixed issue #192 in 3.3.1-fix-plu --- SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot b/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot index 496319b49..9baf42f52 100644 --- a/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot +++ b/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot @@ -132,5 +132,5 @@ Check resource existence Set Headers {"Accept":"${ACCEPT}"} Set Headers {"Content-Type": "${CONTENT_TYPE}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_instances/${vnfInstanceId} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_instances/${instantiatedVnfInstanceId} Integer response status 200 \ No newline at end of file -- GitLab From 2e629660d74cad90f75e083e0e2f721cdefeb6ca Mon Sep 17 00:00:00 2001 From: muhammadh Date: Tue, 28 Sep 2021 13:08:31 +0500 Subject: [PATCH 09/15] fixed VNFD parsing in SOL002 VNF-LCM-API --- .../VnfLcmOperationKeywords.robot | 23 +- .../descriptors/SOL001/VNFD/vnfd_SOL001.yaml | 221 +++++++++--------- .../environment/variables.txt | 2 + 3 files changed, 127 insertions(+), 119 deletions(-) diff --git a/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot b/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot index 9a9fb2659..45395980a 100644 --- a/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot +++ b/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot @@ -1463,8 +1463,17 @@ Fetch Information from SOL001 descriptor file @{VirtualLink_labels}= Create List @{CP_labels}= Create List @{Storage_labels}= Create List + + FOR ${key} IN @{node_types.keys()} + ${node_type}= Get Variable Value ${node_types['${key}']['derived_from']} + ${is_VNF}= Run Keyword And Return Status Should Be Equal As Strings ${node_type} ${tosca_type_VNF} + Run Keyword If ${is_VNF} Set Global Variable ${tosca_type_derived_from_VNF} ${key} + END + ${derived_type_is_used}= Run Keyword And Return Status Should not be empty ${tosca_type_derived_from_VNF} + Run Keyword If ${derived_type_is_used} Set Global Variable ${tosca_type_VNF} ${tosca_type_derived_from_VNF} + FOR ${key} IN @{topology_template.node_templates.keys()} - ${key_type}= Get Variable Value ${topology_template.node_templates.${key}.type} + ${key_type}= Get Variable Value ${topology_template.node_templates['${key}'].type} ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} ${VNF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VNF} ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} @@ -1486,12 +1495,12 @@ Fetch Information from SOL001 descriptor file Get VNF Attributes from SOL001 [Arguments] ${VNF_label} Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - ${descriptor_id}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.descriptor_id} - ${provider}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.provider} - ${product_name}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.product_name} - ${software_version}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.software_version} - ${descriptor_version}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.descriptor_version} - ${flavour_id}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.flavour_id} + ${descriptor_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_id} + ${provider}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.provider} + ${product_name}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.product_name} + ${software_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.software_version} + ${descriptor_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_version} + ${flavour_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.flavour_id} Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} diff --git a/SOL002/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml b/SOL002/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml index e9159106a..04f00443c 100644 --- a/SOL002/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml +++ b/SOL002/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml @@ -1,73 +1,114 @@ tosca_definitions_version: tosca_simple_yaml_1_2 description: "TST010 reference VNF-B" + +imports: + - https://forge.etsi.org/rep/nfv/SOL001/raw/v3.3.1/etsi_nfv_sol001_vnfd_types.yaml + metadata: descriptor_id: "VNF-B" vendor: "ETSI TST WG" version: "2.0" + +node_types: + tst010.vnf.simple: + derived_from: tosca.nodes.nfv.VNF + properties: + descriptor_id: + type: string + default: VNF-B + descriptor_version: + type: string + default: '1.0' + provider: + type: string + default: ETSI TST WG + product_name: + type: string + default: VNF-B + software_version: + type: string + default: '1.0' + product_info_name: + type: string + default: VNF-B + product_info_description: + type: string + default: TST010 reference VNF-B + flavour_id: + type: string + default: VNF-B_flavor + flavour_description: + type: string + default: "VNF-B flavor" + vnfm_info: + type: list + entry_schema: + type: string + default: [ 'etsivnfm:v2.3.1' ] + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + description: Invoked upon receipt of a Scale VNF request + terminate: + description: Invoked upon receipt Terminate VNF request + operate: + description: Invoked upon receipt of an Operate VNF request + requirements: + - virtual_link_right: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_left: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_management: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 0] + topology_template: substitution_mappings: - node_type: "tosca.nodes.nfv.VNF" + node_type: "tst010.vnf.simple" requirements: + virtual_link_right: + [right, virtual_link_right] virtual_link_management: [management, virtual_link_management] virtual_link_left: [left, virtual_link_left] - virtual_link_right: - [right, virtual_link_right] node_templates: right: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 1 requirements: - virtual_link_right: - virtual_binding: VDU-B-2 + - virtual_binding: VDU-B management: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 0 requirements: - virtual_link_management: - virtual_binding: VDU-B-1 + - virtual_binding: VDU-B left: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 2 requirements: - virtual_link_left: - virtual_binding: VDU-B-1 - internal_vl: - type: "tosca.nodes.nfv.VnfVirtualLink" - properties: - connectivity_type: - layer_protocols: [ ipv4 ] - description: Internal Virtual link in the VNF - vl_profile: - max_bitrate_requirements: - root: 100000 - leaf: 20000 - min_bitrate_requirements: - root: 10000 - leaf: 10000 - internal_vdu_b_1_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 2 - requirements: - - virtual_binding: VDU-B-1 - - virtual_link: internal_vl - internal_vdu_b_2_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 0 - requirements: - - virtual_binding: VDU-B-2 - - virtual_link: internal_vl - vdu_b_1_vsd: + - virtual_binding: VDU-B + vdu-b-1-vsd: type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" properties: virtual_block_storage_data: - size_of_storage: 20 + size_of_storage: 20 GB rdma_enabled: false sw_image_data: name: "vdu-b-1 image" @@ -76,63 +117,15 @@ topology_template: algorithm: "sha-224" hash: "somehashfortst010" container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' + disk_format: qcow2 + min_disk: '1' + min_ram: '2' size: '1' - artifacts: - sw_image: - type: "tosca.artifacts.nfv.SwImage" - file: vdu-b-1.qcow2 - vdu_b_2_vsd: - type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" - properties: - virtual_block_storage_data: - size_of_storage: 20 - rdma_enabled: false - sw_image_data: - name: "vdu-b-2 image" - version: "1.1" - checksum: - algorithm: "sha-224" - hash: "somehashfortst010" - container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' - size: '1' - artifacts: - sw_image: - type: tosca.artifacts.nfv.SwImage - file: vdu-b-2.qcow2 - vnf_b_1_VNF: - type: "tosca.nodes.nfv.VNF" - properties: - descriptor_id: "VNF-B-2VDUs" - descriptor_version: "2.0" - provider: "ETSI TST WG" - product_name: "VNF-B-2VDUs" - software_version: "2.0" - product_info_name: "VNF-B-2VDUs" - product_info_description: "TST010 reference VNF-B with 2 VDUs" - flavour_id: "VNF-B-2VDU_flavor" - flavour_description: "VNF-B with 2 VDUs flavor" - vnfm_info: - etsivnfm: - - v2.3.1 - interfaces: - Vnflcm: - scale: - implementation: scale-example.yaml - terminate: - implementation: terminate-example.yaml - operate: - implementation: operate-example.yaml - VDU_B_1: + VDU-B: type: "tosca.nodes.nfv.Vdu.Compute" properties: name: "vdu-b-1-vcd" - descriptor: "Description of VDU-B-1" + description: "Description of VDU-B-1" vdu_profile: min_number_of_instances: 1 max_number_of_instances: 2 @@ -140,29 +133,33 @@ topology_template: virtual_compute: properties: virtual_memory: - virtual_mem_size: 4096 + virtual_mem_size: 4096 MB numa_enabled: false virtual_cpu: num_virtual_cpu: 2 requirements: - virtual_storage: - - "vdu-b-1-vsd" - VDU_B_2: - type: "tosca.nodes.nfv.Vdu.Compute" + - virtual_storage: vdu-b-1-vsd + + vnf-b-1_VNF: + type: "tst010.vnf.simple" properties: - name: "vdu-b-2-vcd" - descriptor: "Description of VDU-B-2" - vdu_profile: - min_number_of_instances: 1 - max_number_of_instances: 4 - capabilities: - virtual_compute: - properties: - virtual_memory: - virtual_mem_size: 6144 - numa_enabled: false - virtual_cpu: - num_virtual_cpu: 2 - requirements: - virtual_storage: - - "vdu-b-2-vsd" \ No newline at end of file + descriptor_id: "VNF-B" + descriptor_version: "2.0" + provider: "ETSI TST WG" + product_name: "VDU_VNF-B" + software_version: "2.0" + product_info_name: "VDU_VNF-B" + product_info_description: "TST010 reference VNF-A" + flavour_id: "VNF-B_flavor" + flavour_description: "VNF-B flavor" + vnfm_info: + - etsivnfm:v2.3.1 + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + implementation: scale-example.yaml + terminate: + implementation: terminate-example.yaml + operate: + implementation: operate-example.yaml \ No newline at end of file diff --git a/SOL002/VNFLifecycleManagement-API/environment/variables.txt b/SOL002/VNFLifecycleManagement-API/environment/variables.txt index 4c3960dbd..2b40b0675 100644 --- a/SOL002/VNFLifecycleManagement-API/environment/variables.txt +++ b/SOL002/VNFLifecycleManagement-API/environment/variables.txt @@ -95,11 +95,13 @@ ${check_descriptors} 1 ${descriptorType} SOL006 ${check_multiple_instances} 0 +#############internal variables used for descriptor parsing################ ${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute ${tosca_type_VNF} tosca.nodes.nfv.VNF ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage +${tosca_type_derived_from_VNF} ${VDU_IDs} ${VNF_IDs} -- GitLab From 6b64ca06290643092063046e968920b264bff19c Mon Sep 17 00:00:00 2001 From: muhammadh Date: Tue, 28 Sep 2021 13:41:59 +0500 Subject: [PATCH 10/15] fixed VNFD parsing in SOL003 APIs --- .../VnfLcmMntOperationKeywords.robot | 22 +- .../descriptors/SOL001/VNFD/vnfd_SOL001.yaml | 221 ++++++------- .../environment/variables.txt | 4 +- .../Grants.robot | 139 +------- .../IndividualGrant.robot | 148 +-------- ...NFLifecycleOperationGrantingKeywords.robot | 311 ++++++++++++++++++ .../descriptors/SOL001/VNFD/vnfd_SOL001.yaml | 221 ++++++------- .../VNFPackageManagementKeywords.robot | 115 ++++++- .../descriptors/SOL001/VNFD/vnfd_SOL001.yaml | 221 ++++++------- .../environment/variables.txt | 19 +- 10 files changed, 789 insertions(+), 632 deletions(-) create mode 100644 SOL003/VNFLifecycleOperationGranting-API/VNFLifecycleOperationGrantingKeywords.robot diff --git a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot index 82d820f54..7c2aed5f8 100644 --- a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot +++ b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot @@ -1517,8 +1517,16 @@ Fetch Information from SOL001 descriptor file @{VirtualLink_labels}= Create List @{CP_labels}= Create List @{Storage_labels}= Create List + FOR ${key} IN @{node_types.keys()} + ${node_type}= Get Variable Value ${node_types['${key}']['derived_from']} + ${is_VNF}= Run Keyword And Return Status Should Be Equal As Strings ${node_type} ${tosca_type_VNF} + Run Keyword If ${is_VNF} Set Global Variable ${tosca_type_derived_from_VNF} ${key} + END + ${derived_type_is_used}= Run Keyword And Return Status Should not be empty ${tosca_type_derived_from_VNF} + Run Keyword If ${derived_type_is_used} Set Global Variable ${tosca_type_VNF} ${tosca_type_derived_from_VNF} + FOR ${key} IN @{topology_template.node_templates.keys()} - ${key_type}= Get Variable Value ${topology_template.node_templates.${key}.type} + ${key_type}= Get Variable Value ${topology_template.node_templates['${key}'].type} ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} ${VNF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VNF} ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} @@ -1540,12 +1548,12 @@ Fetch Information from SOL001 descriptor file Get VNF Attributes from SOL001 [Arguments] ${VNF_label} Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - ${descriptor_id}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.descriptor_id} - ${provider}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.provider} - ${product_name}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.product_name} - ${software_version}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.software_version} - ${descriptor_version}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.descriptor_version} - ${flavour_id}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.flavour_id} + ${descriptor_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_id} + ${provider}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.provider} + ${product_name}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.product_name} + ${software_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.software_version} + ${descriptor_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_version} + ${flavour_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.flavour_id} Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} diff --git a/SOL003/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml b/SOL003/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml index e9159106a..0e0688b94 100644 --- a/SOL003/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml +++ b/SOL003/VNFLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml @@ -1,73 +1,114 @@ tosca_definitions_version: tosca_simple_yaml_1_2 description: "TST010 reference VNF-B" + +imports: + - https://forge.etsi.org/rep/nfv/SOL001/raw/v3.3.1/etsi_nfv_sol001_vnfd_types.yaml + metadata: descriptor_id: "VNF-B" vendor: "ETSI TST WG" version: "2.0" + + node_types: + tst010.vnf.simple: + derived_from: tosca.nodes.nfv.VNF + properties: + descriptor_id: + type: string + default: VNF-B + descriptor_version: + type: string + default: '1.0' + provider: + type: string + default: ETSI TST WG + product_name: + type: string + default: VNF-B + software_version: + type: string + default: '1.0' + product_info_name: + type: string + default: VNF-B + product_info_description: + type: string + default: TST010 reference VNF-B + flavour_id: + type: string + default: VNF-B_flavor + flavour_description: + type: string + default: "VNF-B flavor" + vnfm_info: + type: list + entry_schema: + type: string + default: [ 'etsivnfm:v2.3.1' ] + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + description: Invoked upon receipt of a Scale VNF request + terminate: + description: Invoked upon receipt Terminate VNF request + operate: + description: Invoked upon receipt of an Operate VNF request + requirements: + - virtual_link_right: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_left: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_management: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 0] + topology_template: substitution_mappings: - node_type: "tosca.nodes.nfv.VNF" + node_type: "tst010.vnf.simple" requirements: + virtual_link_right: + [right, virtual_link_right] virtual_link_management: [management, virtual_link_management] virtual_link_left: [left, virtual_link_left] - virtual_link_right: - [right, virtual_link_right] node_templates: right: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 1 requirements: - virtual_link_right: - virtual_binding: VDU-B-2 + - virtual_binding: VDU-B management: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 0 requirements: - virtual_link_management: - virtual_binding: VDU-B-1 + - virtual_binding: VDU-B left: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 2 requirements: - virtual_link_left: - virtual_binding: VDU-B-1 - internal_vl: - type: "tosca.nodes.nfv.VnfVirtualLink" - properties: - connectivity_type: - layer_protocols: [ ipv4 ] - description: Internal Virtual link in the VNF - vl_profile: - max_bitrate_requirements: - root: 100000 - leaf: 20000 - min_bitrate_requirements: - root: 10000 - leaf: 10000 - internal_vdu_b_1_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 2 - requirements: - - virtual_binding: VDU-B-1 - - virtual_link: internal_vl - internal_vdu_b_2_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 0 - requirements: - - virtual_binding: VDU-B-2 - - virtual_link: internal_vl - vdu_b_1_vsd: + - virtual_binding: VDU-B + vdu-b-1-vsd: type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" properties: virtual_block_storage_data: - size_of_storage: 20 + size_of_storage: 20 GB rdma_enabled: false sw_image_data: name: "vdu-b-1 image" @@ -76,63 +117,15 @@ topology_template: algorithm: "sha-224" hash: "somehashfortst010" container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' + disk_format: qcow2 + min_disk: '1' + min_ram: '2' size: '1' - artifacts: - sw_image: - type: "tosca.artifacts.nfv.SwImage" - file: vdu-b-1.qcow2 - vdu_b_2_vsd: - type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" - properties: - virtual_block_storage_data: - size_of_storage: 20 - rdma_enabled: false - sw_image_data: - name: "vdu-b-2 image" - version: "1.1" - checksum: - algorithm: "sha-224" - hash: "somehashfortst010" - container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' - size: '1' - artifacts: - sw_image: - type: tosca.artifacts.nfv.SwImage - file: vdu-b-2.qcow2 - vnf_b_1_VNF: - type: "tosca.nodes.nfv.VNF" - properties: - descriptor_id: "VNF-B-2VDUs" - descriptor_version: "2.0" - provider: "ETSI TST WG" - product_name: "VNF-B-2VDUs" - software_version: "2.0" - product_info_name: "VNF-B-2VDUs" - product_info_description: "TST010 reference VNF-B with 2 VDUs" - flavour_id: "VNF-B-2VDU_flavor" - flavour_description: "VNF-B with 2 VDUs flavor" - vnfm_info: - etsivnfm: - - v2.3.1 - interfaces: - Vnflcm: - scale: - implementation: scale-example.yaml - terminate: - implementation: terminate-example.yaml - operate: - implementation: operate-example.yaml - VDU_B_1: + VDU-B: type: "tosca.nodes.nfv.Vdu.Compute" properties: name: "vdu-b-1-vcd" - descriptor: "Description of VDU-B-1" + description: "Description of VDU-B-1" vdu_profile: min_number_of_instances: 1 max_number_of_instances: 2 @@ -140,29 +133,33 @@ topology_template: virtual_compute: properties: virtual_memory: - virtual_mem_size: 4096 + virtual_mem_size: 4096 MB numa_enabled: false virtual_cpu: num_virtual_cpu: 2 requirements: - virtual_storage: - - "vdu-b-1-vsd" - VDU_B_2: - type: "tosca.nodes.nfv.Vdu.Compute" + - virtual_storage: vdu-b-1-vsd + + vnf-b-1_VNF: + type: "tst010.vnf.simple" properties: - name: "vdu-b-2-vcd" - descriptor: "Description of VDU-B-2" - vdu_profile: - min_number_of_instances: 1 - max_number_of_instances: 4 - capabilities: - virtual_compute: - properties: - virtual_memory: - virtual_mem_size: 6144 - numa_enabled: false - virtual_cpu: - num_virtual_cpu: 2 - requirements: - virtual_storage: - - "vdu-b-2-vsd" \ No newline at end of file + descriptor_id: "VNF-B" + descriptor_version: "2.0" + provider: "ETSI TST WG" + product_name: "VDU_VNF-B" + software_version: "2.0" + product_info_name: "VDU_VNF-B" + product_info_description: "TST010 reference VNF-A" + flavour_id: "VNF-B_flavor" + flavour_description: "VNF-B flavor" + vnfm_info: + - etsivnfm:v2.3.1 + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + implementation: scale-example.yaml + terminate: + implementation: terminate-example.yaml + operate: + implementation: operate-example.yaml \ No newline at end of file diff --git a/SOL003/VNFLifecycleManagement-API/environment/variables.txt b/SOL003/VNFLifecycleManagement-API/environment/variables.txt index bb8e1657f..47b61bc5b 100644 --- a/SOL003/VNFLifecycleManagement-API/environment/variables.txt +++ b/SOL003/VNFLifecycleManagement-API/environment/variables.txt @@ -140,12 +140,14 @@ ${callbackResp} localhost ${descriptorType} SOL001 ${check_descriptors} 1 +#############internal variables used for descriptor parsing################ ${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute ${tosca_type_VNF} tosca.nodes.nfv.VNF ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage - +${tosca_type_derived_from_VNF} + ${VDU_IDs} ${VNF_IDs} ${virtualLink_IDs} diff --git a/SOL003/VNFLifecycleOperationGranting-API/Grants.robot b/SOL003/VNFLifecycleOperationGranting-API/Grants.robot index d404f521b..d8636fb18 100644 --- a/SOL003/VNFLifecycleOperationGranting-API/Grants.robot +++ b/SOL003/VNFLifecycleOperationGranting-API/Grants.robot @@ -1,6 +1,7 @@ *** Settings *** Library String -Resource environment/variables.txt +Resource environment/variables.txt +Resource VNFLifecycleOperationGrantingKeywords.robot Library REST ${NFVO_SCHEMA}://${NFVO_HOST}:${NFVO_PORT} ssl_verify=false Library OperatingSystem Library JSONLibrary @@ -12,7 +13,6 @@ Documentation This resource represents grants. The client can use this resour ... from the NFVO to perform a particular VNF lifecycle operation. *** Variables *** -${response} {} ${retry} 2 min ${polling} 10 sec @@ -109,137 +109,4 @@ DELETE Grants - Method not implemented *** Keywords *** Wait for individual grant successful notification - Wait Until Keyword Succeeds ${retry} ${polling} Get an individual grant - Successful -Send Request Grant Request in Synchronous mode - Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiMajorVersion}/grants - Pass Execution If ${SYNC_MODE} == 0 The Granting process is asynchronous mode. Skipping the test - Set Headers {"Accept": "${ACCEPT}"} - Set Headers {"Content-Type": "${CONTENT_TYPE}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Run Keyword If ${check_descriptors} == 1 Add VNF Descriptor Content to Grant Request - ${template}= Get File jsons/grantRequest.json - ${body}= Format String ${template} vnfInstanceId=${vnfInstanceId} vnfLcmOpOccId=${vnfLcmOpOccId} vnfdId=${Descriptor_ID} flavourId=${Flavour_ID} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/grants ${body} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Send Request Grant Request in Asynchronous mode - Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiMajorVersion}/grants - Pass Execution If ${SYNC_MODE} == 1 The Granting process is synchronous mode. Skipping the test - Set Headers {"Accept": "${ACCEPT}"} - Set Headers {"Content-Type": "${CONTENT_TYPE}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Run Keyword If ${check_descriptors} == 1 Add VNF Descriptor Content to Grant Request - ${template}= Get File jsons/grantRequest.json - ${body}= Format String ${template} vnfInstanceId=${vnfInstanceId} vnfLcmOpOccId=${vnfLcmOpOccId} vnfdId=${Descriptor_ID} flavourId=${Flavour_ID} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/grants ${body} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Send Request for a new Grant Forbiden Operation - Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiMajorVersion}/grants - Log The grant request should be rejected - Set Headers {"Accept": "${ACCEPT}"} - Set Headers {"Content-Type": "${CONTENT_TYPE}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Run Keyword If ${check_descriptors} == 1 Add VNF Descriptor Content to Grant Request - ${template}= Get File jsons/grantRejectedRequest.json - ${body}= Format String ${template} vnfInstanceId=${vnfInstanceId} vnfLcmOpOccId=${vnfLcmOpOccId} vnfdId=${Descriptor_ID} flavourId=${Flavour_ID} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/grants ${body} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Check HTTP Response Status Code Is - [Arguments] ${expected_status} - Should Be Equal As Strings ${response['status']} ${expected_status} - Log Status code validated - -Check Operation Occurrence Id existence - ${occId}= Get Value From Json ${response['headers']} $..Location - Should Not Be Empty ${occId} - -Check HTTP Response Header Contains - [Arguments] ${CONTENT_TYPE} - Should Contain ${response['headers']} ${CONTENT_TYPE} - Log Header is present - -Check HTTP Response Body Json Schema Is - [Arguments] ${input} - Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json - ... ELSE Should Contain ${response['headers']['Content-Type']} application/json - ${schema} = Catenate SEPARATOR= ${input} .schema.json - Validate Json ${schema} ${response['body']} - -Get an individual grant - Successful - log Trying to read an individual grant - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${response['headers']['Location']} - Log Validate Status code - Integer response status 200 - -Get Grants - Log Trying to perform a GET. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${apiRoot}/${apiName}/${apiMajorVersion}/grants - ${body}= Output response - Set Suite Variable ${response} ${body} - -Put Grants - Log Trying to perform a PUT. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Put ${apiRoot}/${apiName}/${apiMajorVersion}/grants - ${body}= Output response - Set Suite Variable ${response} ${body} - -Patch Grants - Log Trying to perform a PATCH. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Patch ${apiRoot}/${apiName}/${apiMajorVersion}/grants - ${body}= Output response - Set Suite Variable ${response} ${body} - -Delete Grants - Log Trying to perform a DELETE. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Delete ${apiRoot}/${apiName}/${apiMajorVersion}/grants - ${body}= Output response - Set Suite Variable ${response} ${body} - -Add VNF Descriptor Content to Grant Request - PARSE the Descriptor File - -PARSE the Descriptor File - Run Keyword If '${descriptorType}'=='SOL001' Fetch Information from SOL001 descriptor file ELSE Fetch Information from SOL006 descriptor file - -Fetch Information from SOL001 descriptor file - Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - ${descriptor_id}= Get Variable Value ${topology_template.node_templates.properties.descriptor_id} - ${provider}= Get Variable Value ${topology_template.node_templates.properties.provider} - ${product_name}= Get Variable Value ${topology_template.node_templates.properties.product_name} - ${software_version}= Get Variable Value ${topology_template.node_templates.properties.software_version} - ${descriptor_version}= Get Variable Value ${topology_template.node_templates.properties.descriptor_version} - ${flavour_id}= Get Variable Value ${topology_template.node_templates.properties.flavour_id} - Set Global Variable ${Descriptor_ID} ${descriptor_id} - Set Global Variable ${Provider} ${provider} - Set Global Variable ${Product_Name} ${product_name} - Set Global Variable ${Software_Version} ${software_version} - Set Global Variable ${Descriptor_Version} ${descriptor_version} - Set Global Variable ${Flavour_ID} ${flavour_id} - -Fetch Information from SOL006 descriptor file - Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml - ${descriptor_id}= Get Variable Value ${nfv.vnfd[0].id} - ${provider}= Get Variable Value ${nfv.vnfd[0].provider} - ${product_name}= Get Variable Value ${nfv.vnfd[0]['product-name']} - ${software_version}= Get Variable Value ${nfv.vnfd[0]['software-version']} - ${descriptor_version}= Get Variable Value ${nfv.vnfd[0].version} - Set Global Variable ${Descriptor_ID} ${descriptor_id} - Set Global Variable ${Provider} ${provider} - Set Global Variable ${Product_Name} ${product_name} - Set Global Variable ${Software_Version} ${software_version} - Set Global Variable ${Descriptor_Version} ${descriptor_version} \ No newline at end of file + Wait Until Keyword Succeeds ${retry} ${polling} Get an individual grant - Successful \ No newline at end of file diff --git a/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot b/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot index f018e15ca..cf4e7d026 100644 --- a/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot +++ b/SOL003/VNFLifecycleOperationGranting-API/IndividualGrant.robot @@ -1,5 +1,6 @@ *** Settings *** -Resource environment/variables.txt +Resource environment/variables.txt +Resource VNFLifecycleOperationGrantingKeywords.robot Library OperatingSystem Library JSONLibrary Library JSONSchemaLibrary schemas/ @@ -100,147 +101,4 @@ DELETE an individual grant - Method not implemented ... Applicability: none ... Post-Conditions: none Delete individual Grant - Check HTTP Response Status Code Is 405 - -*** Keywords *** -Get individual grant - log Trying to read an individual grant - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Check resource existence - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions/${subscriptionId} - Integer response status 200 - -Post individual Grant - log Trying to read an individual grant - Pass Execution If ${SYNC_MODE} == 1 Skipping. Synchronous mode is supported - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Get ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Put individual Grant - Log Trying to perform a GET. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Put ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Patch individual Grant - Log Trying to perform a GET. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Patch ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Delete individual Grant - Log Trying to perform a GET. This method should not be implemented - Set Headers {"Accept":"${ACCEPT}"} - Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} - Delete ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} - ${body}= Output response - Set Suite Variable ${response} ${body} - -Check HTTP Response Status Code Is - [Arguments] ${expected_status} - Should Be Equal As Strings ${response['status']} ${expected_status} - Log Status code validated - -Check HTTP Response Header Contains - [Arguments] ${CONTENT_TYPE} - Should Contain ${response['headers']} ${CONTENT_TYPE} - Log Header is present - -Check HTTP Response Body Json Schema Is - [Arguments] ${input} - Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json - ... ELSE Should Contain ${response['headers']['Content-Type']} application/json - ${schema} = Catenate SEPARATOR= ${input} .schema.json - Validate Json ${schema} ${response['body']} - -Check HTTP Response Body grant content against VNF Descriptor - Run Keyword If ${check_descriptors} == 1 Check Individual grant Content - -Check Individual grant Content - PARSE the Descriptor File - Match the grant Response Attributes with Descriptors - -PARSE the Descriptor File - Run Keyword If '${descriptorType}'=='SOL001' Fetch Information from SOL001 descriptor file ELSE Fetch Information from SOL006 descriptor file - -Fetch Information from SOL001 descriptor file - Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - @{VDU_labels}= Create List - @{VirtualLink_labels}= Create List - @{CP_labels}= Create List - FOR ${key} IN @{topology_template.node_templates.keys()} - ${key_type}= Get Variable Value ${topology_template.node_templates.${key}.type} - ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} - ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} - ${VDUcp_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_cp} - Run Keyword If ${VDU_check} Append To List ${VDU_labels} ${key} - Run Keyword If ${Link_check} Append To List ${VirtualLink_labels} ${key} - Run Keyword If ${VDUcp_check} Append To List ${CP_labels} ${key} - END - Set Global Variable @{VDU_IDs} @{VDU_labels} - Set Global Variable @{VirtualLink_IDs} @{VirtualLink_labels} - Set Global Variable @{CP_IDs} @{CP_labels} - -Fetch Information from SOL006 descriptor file - Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml - ${VDUcount}= Get Length ${nfv.vnfd[0].vdu} - ${extCP_count}= Get Length ${nfv.vnfd[0]['ext-cpd']} - ${virtualLink_count}= Get length ${nfv.vnfd[0]['int-virtual-link-desc']} - FOR ${key} IN @{nfv.vnfd[0].keys()} - ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} vdu - Run Keyword If ${VDU_check} Get VDU IDs ${VDUcount} - ${extCP_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} ext-cpd - Run Keyword If ${extCP_check} Get External CP IDs ${extCP_count} - ${virtualLink_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} int-virtual-link-desc - Run Keyword If ${virtualLink_check} Get Virtual Link IDs ${virtualLink_count} - END - -Get VDU IDs - [Arguments] ${count} - Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml - @{VDU_labels}= Create List - @{Compute_labels}= Create List - FOR ${i} IN RANGE ${count} - Append To List ${VDU_labels} ${nfv.vnfd[0].vdu[${i}]['id']} - Append To List ${Compute_labels} ${nfv.vnfd[0].vdu[${i}]['virtual-compute-desc']} - END - Set Global Variable ${VDU_IDs} ${VDU_labels} - Set Global Variable ${Compute_IDs} ${Compute_labels} - -Get External CP IDs - [Arguments] ${count} - Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml - @{external_CPs}= Create List - FOR ${i} IN RANGE ${count} - Append To List ${external_CPs} ${nfv.vnfd[0].ext_cpd[${i}].id} - END - Set Global Variable ${externalCP_IDs} ${external_CPs} - -Get Virtual Link IDs - [Arguments] ${count} - Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml - ${VirtualLink_labels}= Create List - FOR ${i} IN RANGE ${count} - Append To List ${VirtualLink_labels} ${nfv.vnfd[0]['int-virtual-link-desc'][${i}]['id']} - END - Set Global Variable ${VirtualLink_IDs} ${VirtualLink_labels} - -Match the grant Response Attributes with Descriptors - Run Keyword If '${descriptorType}'=='SOL006' List Should Contain Value ${externalCP_IDs} ${response['body']['extVirtualLinks'][0]['extCps'][0]['cpdId']} - Run Keyword If '${descriptorType}'=='SOL001' List Should Contain Value @{CP_IDs} ${response['body']['extVirtualLinks'][0]['extCps'][0]['cpdId']} - List Should Contain Value ${VirtualLink_IDs} ${response['body']['extManagedVirtualLinkData'][0]['vnfVirtualLinkDescId']} - List Should Contain value ${Compute_IDs} ${response['body']['vimAssets']['computeResourceFlavours'][0]['vnfdVirtualComputeDescId']} + Check HTTP Response Status Code Is 405 \ No newline at end of file diff --git a/SOL003/VNFLifecycleOperationGranting-API/VNFLifecycleOperationGrantingKeywords.robot b/SOL003/VNFLifecycleOperationGranting-API/VNFLifecycleOperationGrantingKeywords.robot new file mode 100644 index 000000000..bcc612f9f --- /dev/null +++ b/SOL003/VNFLifecycleOperationGranting-API/VNFLifecycleOperationGrantingKeywords.robot @@ -0,0 +1,311 @@ +*** Settings *** +Library String +Resource environment/variables.txt +Library REST ${NFVO_SCHEMA}://${NFVO_HOST}:${NFVO_PORT} ssl_verify=false +Library OperatingSystem +Library JSONLibrary +Library JSONSchemaLibrary schemas/ +Library Collections + +*** Variables *** +${retry} 2 min +${polling} 10 sec + +*** Keywords *** +Wait for individual grant successful notification + Wait Until Keyword Succeeds ${retry} ${polling} Get an individual grant - Successful +Send Request Grant Request in Synchronous mode + Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiMajorVersion}/grants + Pass Execution If ${SYNC_MODE} == 0 The Granting process is asynchronous mode. Skipping the test + Set Headers {"Accept": "${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Run Keyword If ${check_descriptors} == 1 PARSE the Descriptor File + ${template}= Get File jsons/grantRequest.json + ${body}= Format String ${template} vnfInstanceId=${vnfInstanceId} vnfLcmOpOccId=${vnfLcmOpOccId} vnfdId=${Descriptor_ID} flavourId=${Flavour_ID} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/grants ${body} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Send Request Grant Request in Asynchronous mode + Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiMajorVersion}/grants + Pass Execution If ${SYNC_MODE} == 1 The Granting process is synchronous mode. Skipping the test + Set Headers {"Accept": "${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Run Keyword If ${check_descriptors} == 1 PARSE the Descriptor File + ${template}= Get File jsons/grantRequest.json + ${body}= Format String ${template} vnfInstanceId=${vnfInstanceId} vnfLcmOpOccId=${vnfLcmOpOccId} vnfdId=${Descriptor_ID} flavourId=${Flavour_ID} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/grants ${body} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Send Request for a new Grant Forbiden Operation + Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiMajorVersion}/grants + Log The grant request should be rejected + Set Headers {"Accept": "${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Run Keyword If ${check_descriptors} == 1 PARSE the Descriptor File + ${template}= Get File jsons/grantRejectedRequest.json + ${body}= Format String ${template} vnfInstanceId=${vnfInstanceId} vnfLcmOpOccId=${vnfLcmOpOccId} vnfdId=${Descriptor_ID} flavourId=${Flavour_ID} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/grants ${body} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Check HTTP Response Status Code Is + [Arguments] ${expected_status} + Should Be Equal As Strings ${response['status']} ${expected_status} + Log Status code validated + +Check Operation Occurrence Id existence + ${occId}= Get Value From Json ${response['headers']} $..Location + Should Not Be Empty ${occId} + +Check HTTP Response Header Contains + [Arguments] ${CONTENT_TYPE} + Should Contain ${response['headers']} ${CONTENT_TYPE} + Log Header is present + +Check HTTP Response Body Json Schema Is + [Arguments] ${input} + Run Keyword If '${input}' == 'ProblemDetails' Should Contain ${response['headers']['Content-Type']} application/problem+json + ... ELSE Should Contain ${response['headers']['Content-Type']} application/json + ${schema} = Catenate SEPARATOR= ${input} .schema.json + Validate Json ${schema} ${response['body']} + +Get an individual grant - Successful + log Trying to read an individual grant + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${response['headers']['Location']} + Log Validate Status code + Integer response status 200 + +Get Grants + Log Trying to perform a GET. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/grants + ${body}= Output response + Set Suite Variable ${response} ${body} + +Put Grants + Log Trying to perform a PUT. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/grants + ${body}= Output response + Set Suite Variable ${response} ${body} + +Patch Grants + Log Trying to perform a PATCH. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/grants + ${body}= Output response + Set Suite Variable ${response} ${body} + +Delete Grants + Log Trying to perform a DELETE. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Delete ${apiRoot}/${apiName}/${apiMajorVersion}/grants + ${body}= Output response + Set Suite Variable ${response} ${body} + + +Get individual grant + log Trying to read an individual grant + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Check resource existence + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions/${subscriptionId} + Integer response status 200 + +Post individual Grant + log Trying to read an individual grant + Pass Execution If ${SYNC_MODE} == 1 Skipping. Synchronous mode is supported + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Get ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Put individual Grant + Log Trying to perform a GET. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Put ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Patch individual Grant + Log Trying to perform a GET. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Delete individual Grant + Log Trying to perform a GET. This method should not be implemented + Set Headers {"Accept":"${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Delete ${apiRoot}/${apiName}/${apiMajorVersion}/grants/${grantId} + ${body}= Output response + Set Suite Variable ${response} ${body} + +Check HTTP Response Body grant content against VNF Descriptor + Run Keyword If ${check_descriptors} == 1 Check Individual grant Content + +Check Individual grant Content + PARSE the Descriptor File + Match the grant Response Attributes with Descriptors + +PARSE the Descriptor File + Run Keyword If '${descriptorType}'=='SOL001' Fetch Information from SOL001 descriptor file ELSE Fetch Information from SOL006 descriptor file + +Fetch Information from SOL001 descriptor file + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL001.yaml + @{VDU_labels}= Create List + @{VNF_labels}= Create List + @{VirtualLink_labels}= Create List + @{CP_labels}= Create List + @{Storage_labels}= Create List + FOR ${key} IN @{node_types.keys()} + ${node_type}= Get Variable Value ${node_types['${key}']['derived_from']} + ${is_VNF}= Run Keyword And Return Status Should Be Equal As Strings ${node_type} ${tosca_type_VNF} + Run Keyword If ${is_VNF} Set Global Variable ${tosca_type_derived_from_VNF} ${key} + END + ${derived_type_is_used}= Run Keyword And Return Status Should not be empty ${tosca_type_derived_from_VNF} + Run Keyword If ${derived_type_is_used} Set Global Variable ${tosca_type_VNF} ${tosca_type_derived_from_VNF} + FOR ${key} IN @{topology_template.node_templates.keys()} + ${key_type}= Get Variable Value ${topology_template.node_templates['${key}'].type} + ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} + ${VNF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VNF} + ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} + ${VDUcp_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_cp} + ${Storage_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_storage} + Run Keyword If ${VDU_check} Append To List ${VDU_labels} ${key} + Run Keyword If ${VNF_check} Append To List ${VNF_labels} ${key} + Run Keyword If ${VNF_check} Get VNF Attributes from SOL001 ${key} + Run Keyword If ${Link_check} Append To List ${VirtualLink_labels} ${key} + Run Keyword If ${VDUcp_check} Append To List ${CP_labels} ${key} + Run Keyword If ${Storage_check} Append To List ${Storage_labels} ${key} + END + Set Global Variable @{VDU_IDs} @{VDU_labels} + Set Global Variable @{VNF_IDs} @{VNF_labels} + Set Global Variable @{VirtualLink_IDs} @{VirtualLink_labels} + Set Global Variable @{CP_IDs} @{CP_labels} + Set Global Variable @{Storage_IDs} @{Storage_labels} + +Get VNF Attributes from SOL001 + [Arguments] ${VNF_label} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL001.yaml + ${descriptor_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_id} + ${provider}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.provider} + ${product_name}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.product_name} + ${software_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.software_version} + ${descriptor_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_version} + ${flavour_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.flavour_id} + + Set Global Variable ${Descriptor_ID} ${descriptor_id} + Set Global Variable ${Provider} ${provider} + Set Global Variable ${Product_Name} ${product_name} + Set Global Variable ${Software_Version} ${software_version} + Set Global Variable ${Descriptor_Version} ${descriptor_version} + Set Global Variable ${Flavour_ID} ${flavour_id} + + +Fetch Information from SOL006 descriptor file + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + ${descriptor_id}= Get Variable Value ${nfv.vnfd[0].id} + ${provider}= Get Variable Value ${nfv.vnfd[0].provider} + ${product_name}= Get Variable Value ${nfv.vnfd[0]['product-name']} + ${software_version}= Get Variable Value ${nfv.vnfd[0]['software-version']} + ${descriptor_version}= Get Variable Value ${nfv.vnfd[0].version} + ${VDUcount}= Get Length ${nfv.vnfd[0].vdu} + ${extCP_count}= Get Length ${nfv.vnfd[0]['ext-cpd']} + ${virtualLink_count}= Get length ${nfv.vnfd[0]['int-virtual-link-desc']} + ${instantiation_levels}= Get Length ${nfv.vnfd[0].df['instantiation-level']} + FOR ${key} IN @{nfv.vnfd[0].keys()} + ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} vdu + Run Keyword If ${VDU_check} Get VDU IDs ${VDUcount} + ${extCP_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} ext-cpd + Run Keyword If ${extCP_check} Get External CP IDs ${extCP_count} + ${virtualLink_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} int-virtual-link-desc + Run Keyword If ${virtualLink_check} Get Virtual Link IDs ${virtualLink_count} + ${DF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} df + Run Keyword If ${DF_check} Get Instantiation Levels ${instantiation_levels} + END + Set Global Variable ${Descriptor_ID} ${descriptor_id} + Set Global Variable ${Provider} ${provider} + Set Global Variable ${Product_Name} ${product_name} + Set Global Variable ${Software_Version} ${software_version} + Set Global Variable ${Descriptor_Version} ${descriptor_version} + +Get VDU IDs + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + @{VDU_labels}= Create List + ${Storage_labels}= Create List + ${Compute_labels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${VDU_labels} ${nfv.vnfd[0].vdu[${i}]['id']} + Append To List ${Storage_labels} ${nfv.vnfd[0].vdu[${i}]['virtual-storage-desc']} + Append To List ${Compute_labels} ${nfv.vnfd[0].vdu[${i}]['virtual-compute-desc']} + Get Internal CPs for each VDU ${i} + END + Set Global Variable ${VDU_IDs} ${VDU_labels} + Set Global Variable ${Storage_IDs} ${Storage_labels} + Set Global Variable ${Compute_IDs} ${Compute_labels} + +Get Internal CPs for each VDU + [Arguments] ${vdu} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + ${count}= Get Length ${nfv.vnfd[0].vdu[${vdu}]['int-cpd']} + ${internal_CPs}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${internal_CPs} ${nfv.vnfd[0].vdu[${vdu}]['int-cpd'][${i}]['id']} + END + Set Global Variable ${internalCP_IDs} ${internal_CPs} + +Get External CP IDs + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + @{external_CPs}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${external_CPs} ${nfv.vnfd[0].ext_cpd[${i}].id} + END + Set Global Variable ${externalCP_IDs} ${external_CPs} + +Get Virtual Link IDs + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + ${VirtualLink_labels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${VirtualLink_labels} ${nfv.vnfd[0]['int-virtual-link-desc'][${i}]['id']} + END + Set Global Variable ${VirtualLink_IDs} ${VirtualLink_labels} + +Get Instantiation Levels + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + @{Instantiation_Levels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${Instantiation_Levels} ${nfv.vnfd[0].df['instantiation-level'][${i}]['id']} + END + Set Global Variable ${InstantiationLevel_IDs} ${Instantiation_Levels} + +Match the grant Response Attributes with Descriptors + Run Keyword If '${descriptorType}'=='SOL006' List Should Contain Value ${externalCP_IDs} ${response['body']['extVirtualLinks'][0]['extCps'][0]['cpdId']} + Run Keyword If '${descriptorType}'=='SOL001' List Should Contain Value @{CP_IDs} ${response['body']['extVirtualLinks'][0]['extCps'][0]['cpdId']} + List Should Contain Value ${VirtualLink_IDs} ${response['body']['extManagedVirtualLinkData'][0]['vnfVirtualLinkDescId']} + List Should Contain value ${Compute_IDs} ${response['body']['vimAssets']['computeResourceFlavours'][0]['vnfdVirtualComputeDescId']} \ No newline at end of file diff --git a/SOL003/VNFLifecycleOperationGranting-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml b/SOL003/VNFLifecycleOperationGranting-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml index e9159106a..603b1887d 100644 --- a/SOL003/VNFLifecycleOperationGranting-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml +++ b/SOL003/VNFLifecycleOperationGranting-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml @@ -1,73 +1,114 @@ tosca_definitions_version: tosca_simple_yaml_1_2 description: "TST010 reference VNF-B" + +imports: + - https://forge.etsi.org/rep/nfv/SOL001/raw/v3.3.1/etsi_nfv_sol001_vnfd_types.yaml + metadata: descriptor_id: "VNF-B" vendor: "ETSI TST WG" version: "2.0" + +node_types: + tst010.vnf.simple: + derived_from: tosca.nodes.nfv.VNF + properties: + descriptor_id: + type: string + default: VNF-B + descriptor_version: + type: string + default: '1.0' + provider: + type: string + default: ETSI TST WG + product_name: + type: string + default: VNF-B + software_version: + type: string + default: '1.0' + product_info_name: + type: string + default: VNF-B + product_info_description: + type: string + default: TST010 reference VNF-B + flavour_id: + type: string + default: VNF-B_flavor + flavour_description: + type: string + default: "VNF-B flavor" + vnfm_info: + type: list + entry_schema: + type: string + default: [ 'etsivnfm:v2.3.1' ] + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + description: Invoked upon receipt of a Scale VNF request + terminate: + description: Invoked upon receipt Terminate VNF request + operate: + description: Invoked upon receipt of an Operate VNF request + requirements: + - virtual_link_right: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_left: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_management: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 0] + topology_template: substitution_mappings: - node_type: "tosca.nodes.nfv.VNF" + node_type: "tst010.vnf.simple" requirements: + virtual_link_right: + [right, virtual_link_right] virtual_link_management: [management, virtual_link_management] virtual_link_left: [left, virtual_link_left] - virtual_link_right: - [right, virtual_link_right] node_templates: right: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 1 requirements: - virtual_link_right: - virtual_binding: VDU-B-2 + - virtual_binding: VDU-B management: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 0 requirements: - virtual_link_management: - virtual_binding: VDU-B-1 + - virtual_binding: VDU-B left: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 2 requirements: - virtual_link_left: - virtual_binding: VDU-B-1 - internal_vl: - type: "tosca.nodes.nfv.VnfVirtualLink" - properties: - connectivity_type: - layer_protocols: [ ipv4 ] - description: Internal Virtual link in the VNF - vl_profile: - max_bitrate_requirements: - root: 100000 - leaf: 20000 - min_bitrate_requirements: - root: 10000 - leaf: 10000 - internal_vdu_b_1_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 2 - requirements: - - virtual_binding: VDU-B-1 - - virtual_link: internal_vl - internal_vdu_b_2_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 0 - requirements: - - virtual_binding: VDU-B-2 - - virtual_link: internal_vl - vdu_b_1_vsd: + - virtual_binding: VDU-B + vdu-b-1-vsd: type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" properties: virtual_block_storage_data: - size_of_storage: 20 + size_of_storage: 20 GB rdma_enabled: false sw_image_data: name: "vdu-b-1 image" @@ -76,63 +117,15 @@ topology_template: algorithm: "sha-224" hash: "somehashfortst010" container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' + disk_format: qcow2 + min_disk: '1' + min_ram: '2' size: '1' - artifacts: - sw_image: - type: "tosca.artifacts.nfv.SwImage" - file: vdu-b-1.qcow2 - vdu_b_2_vsd: - type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" - properties: - virtual_block_storage_data: - size_of_storage: 20 - rdma_enabled: false - sw_image_data: - name: "vdu-b-2 image" - version: "1.1" - checksum: - algorithm: "sha-224" - hash: "somehashfortst010" - container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' - size: '1' - artifacts: - sw_image: - type: tosca.artifacts.nfv.SwImage - file: vdu-b-2.qcow2 - vnf_b_1_VNF: - type: "tosca.nodes.nfv.VNF" - properties: - descriptor_id: "VNF-B-2VDUs" - descriptor_version: "2.0" - provider: "ETSI TST WG" - product_name: "VNF-B-2VDUs" - software_version: "2.0" - product_info_name: "VNF-B-2VDUs" - product_info_description: "TST010 reference VNF-B with 2 VDUs" - flavour_id: "VNF-B-2VDU_flavor" - flavour_description: "VNF-B with 2 VDUs flavor" - vnfm_info: - etsivnfm: - - v2.3.1 - interfaces: - Vnflcm: - scale: - implementation: scale-example.yaml - terminate: - implementation: terminate-example.yaml - operate: - implementation: operate-example.yaml - VDU_B_1: + VDU-B: type: "tosca.nodes.nfv.Vdu.Compute" properties: name: "vdu-b-1-vcd" - descriptor: "Description of VDU-B-1" + description: "Description of VDU-B-1" vdu_profile: min_number_of_instances: 1 max_number_of_instances: 2 @@ -140,29 +133,33 @@ topology_template: virtual_compute: properties: virtual_memory: - virtual_mem_size: 4096 + virtual_mem_size: 4096 MB numa_enabled: false virtual_cpu: num_virtual_cpu: 2 requirements: - virtual_storage: - - "vdu-b-1-vsd" - VDU_B_2: - type: "tosca.nodes.nfv.Vdu.Compute" + - virtual_storage: vdu-b-1-vsd + + vnf-b-1_VNF: + type: "tst010.vnf.simple" properties: - name: "vdu-b-2-vcd" - descriptor: "Description of VDU-B-2" - vdu_profile: - min_number_of_instances: 1 - max_number_of_instances: 4 - capabilities: - virtual_compute: - properties: - virtual_memory: - virtual_mem_size: 6144 - numa_enabled: false - virtual_cpu: - num_virtual_cpu: 2 - requirements: - virtual_storage: - - "vdu-b-2-vsd" \ No newline at end of file + descriptor_id: "VNF-B" + descriptor_version: "2.0" + provider: "ETSI TST WG" + product_name: "VDU_VNF-B" + software_version: "2.0" + product_info_name: "VDU_VNF-B" + product_info_description: "TST010 reference VNF-A" + flavour_id: "VNF-B_flavor" + flavour_description: "VNF-B flavor" + vnfm_info: + - etsivnfm:v2.3.1 + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + implementation: scale-example.yaml + terminate: + implementation: terminate-example.yaml + operate: + implementation: operate-example.yaml \ No newline at end of file diff --git a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index 0e268af7b..f2f5d6687 100644 --- a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -1627,16 +1627,54 @@ PARSE the Descriptor File Fetch Information from SOL001 descriptor file Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - ${descriptor_id}= Get Variable Value ${topology_template.node_templates.properties.descriptor_id} - ${provider}= Get Variable Value ${topology_template.node_templates.properties.provider} - ${product_name}= Get Variable Value ${topology_template.node_templates.properties.product_name} - ${software_version}= Get Variable Value ${topology_template.node_templates.properties.software_version} - ${descriptor_version}= Get Variable Value ${topology_template.node_templates.properties.descriptor_version} + @{VDU_labels}= Create List + @{VNF_labels}= Create List + @{VirtualLink_labels}= Create List + @{CP_labels}= Create List + @{Storage_labels}= Create List + FOR ${key} IN @{node_types.keys()} + ${node_type}= Get Variable Value ${node_types['${key}']['derived_from']} + ${is_VNF}= Run Keyword And Return Status Should Be Equal As Strings ${node_type} ${tosca_type_VNF} + Run Keyword If ${is_VNF} Set Global Variable ${tosca_type_derived_from_VNF} ${key} + END + ${derived_type_is_used}= Run Keyword And Return Status Should not be empty ${tosca_type_derived_from_VNF} + Run Keyword If ${derived_type_is_used} Set Global Variable ${tosca_type_VNF} ${tosca_type_derived_from_VNF} + FOR ${key} IN @{topology_template.node_templates.keys()} + ${key_type}= Get Variable Value ${topology_template.node_templates['${key}'].type} + ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} + ${VNF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VNF} + ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} + ${VDUcp_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_cp} + ${Storage_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_storage} + Run Keyword If ${VDU_check} Append To List ${VDU_labels} ${key} + Run Keyword If ${VNF_check} Append To List ${VNF_labels} ${key} + Run Keyword If ${VNF_check} Get VNF Attributes from SOL001 ${key} + Run Keyword If ${Link_check} Append To List ${VirtualLink_labels} ${key} + Run Keyword If ${VDUcp_check} Append To List ${CP_labels} ${key} + Run Keyword If ${Storage_check} Append To List ${Storage_labels} ${key} + END + Set Global Variable @{VDU_IDs} @{VDU_labels} + Set Global Variable @{VNF_IDs} @{VNF_labels} + Set Global Variable @{VirtualLink_IDs} @{VirtualLink_labels} + Set Global Variable @{CP_IDs} @{CP_labels} + Set Global Variable @{Storage_IDs} @{Storage_labels} + +Get VNF Attributes from SOL001 + [Arguments] ${VNF_label} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL001.yaml + ${descriptor_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_id} + ${provider}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.provider} + ${product_name}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.product_name} + ${software_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.software_version} + ${descriptor_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_version} + ${flavour_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.flavour_id} + Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} Set Global Variable ${Product_Name} ${product_name} Set Global Variable ${Software_Version} ${software_version} Set Global Variable ${Descriptor_Version} ${descriptor_version} + Set Global Variable ${Flavour_ID} ${flavour_id} Fetch Information from SOL006 descriptor file Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml @@ -1644,13 +1682,78 @@ Fetch Information from SOL006 descriptor file ${provider}= Get Variable Value ${nfv.vnfd[0].provider} ${product_name}= Get Variable Value ${nfv.vnfd[0]['product-name']} ${software_version}= Get Variable Value ${nfv.vnfd[0]['software-version']} - ${descriptor_version}= Get Variable Value ${nfv.vnfd[0].version} + ${descriptor_version}= Get Variable Value ${nfv.vnfd[0].version} + ${VDUcount}= Get Length ${nfv.vnfd[0].vdu} + ${extCP_count}= Get Length ${nfv.vnfd[0]['ext-cpd']} + ${virtualLink_count}= Get length ${nfv.vnfd[0]['int-virtual-link-desc']} + ${instantiation_levels}= Get Length ${nfv.vnfd[0].df['instantiation-level']} + FOR ${key} IN @{nfv.vnfd[0].keys()} + ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} vdu + Run Keyword If ${VDU_check} Get VDU IDs ${VDUcount} + ${extCP_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} ext-cpd + Run Keyword If ${extCP_check} Get External CP IDs ${extCP_count} + ${virtualLink_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} int-virtual-link-desc + Run Keyword If ${virtualLink_check} Get Virtual Link IDs ${virtualLink_count} + ${DF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} df + Run Keyword If ${DF_check} Get Instantiation Levels ${instantiation_levels} + END + Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} Set Global Variable ${Product_Name} ${product_name} Set Global Variable ${Software_Version} ${software_version} Set Global Variable ${Descriptor_Version} ${descriptor_version} +Get VDU IDs + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + @{VDU_labels}= Create List + ${Storage_labels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${VDU_labels} ${nfv.vnfd[0].vdu[${i}]['id']} + Append To List ${Storage_labels} ${nfv.vnfd[0].vdu[${i}]['virtual-storage-desc']} + Get Internal CPs for each VDU ${i} + END + Set Global Variable ${VDU_IDs} ${VDU_labels} + Set Global Variable ${Storage_IDs} ${Storage_labels} + +Get Internal CPs for each VDU + [Arguments] ${vdu} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + ${count}= Get Length ${nfv.vnfd[0].vdu[${vdu}]['int-cpd']} + ${internal_CPs}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${internal_CPs} ${nfv.vnfd[0].vdu[${vdu}]['int-cpd'][${i}]['id']} + END + Set Global Variable ${internalCP_IDs} ${internal_CPs} + +Get External CP IDs + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + @{external_CPs}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${external_CPs} ${nfv.vnfd[0].ext_cpd[${i}].id} + END + Set Global Variable ${externalCP_IDs} ${external_CPs} + +Get Virtual Link IDs + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + ${VirtualLink_labels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${VirtualLink_labels} ${nfv.vnfd[0]['int-virtual-link-desc'][${i}]['id']} + END + Set Global Variable ${VirtualLink_IDs} ${VirtualLink_labels} + +Get Instantiation Levels + [Arguments] ${count} + Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml + @{Instantiation_Levels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${Instantiation_Levels} ${nfv.vnfd[0].df['instantiation-level'][${i}]['id']} + END + Set Global Variable ${InstantiationLevel_IDs} ${Instantiation_Levels} + Match the VNF Package Response Attributes with Descriptors #Checking Response attributes with VNF Descriptors Should Be Equal As Strings ${response['body']['vnfdId']} ${Descriptor_ID} diff --git a/SOL003/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml b/SOL003/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml index e9159106a..1d3878732 100644 --- a/SOL003/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml +++ b/SOL003/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml @@ -1,73 +1,114 @@ tosca_definitions_version: tosca_simple_yaml_1_2 description: "TST010 reference VNF-B" + +imports: + - https://forge.etsi.org/rep/nfv/SOL001/raw/v3.3.1/etsi_nfv_sol001_vnfd_types.yaml + metadata: descriptor_id: "VNF-B" vendor: "ETSI TST WG" version: "2.0" + +node_types: + tst010.vnf.simple: + derived_from: tosca.nodes.nfv.VNF + properties: + descriptor_id: + type: string + default: VNF-B + descriptor_version: + type: string + default: '1.0' + provider: + type: string + default: ETSI TST WG + product_name: + type: string + default: VNF-B + software_version: + type: string + default: '1.0' + product_info_name: + type: string + default: VNF-B + product_info_description: + type: string + default: TST010 reference VNF-B + flavour_id: + type: string + default: VNF-B_flavor + flavour_description: + type: string + default: "VNF-B flavor" + vnfm_info: + type: list + entry_schema: + type: string + default: [ 'etsivnfm:v2.3.1' ] + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + description: Invoked upon receipt of a Scale VNF request + terminate: + description: Invoked upon receipt Terminate VNF request + operate: + description: Invoked upon receipt of an Operate VNF request + requirements: + - virtual_link_right: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_left: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_management: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 0] + topology_template: substitution_mappings: - node_type: "tosca.nodes.nfv.VNF" + node_type: "tst010.vnf.simple" requirements: + virtual_link_right: + [right, virtual_link_right] virtual_link_management: [management, virtual_link_management] virtual_link_left: [left, virtual_link_left] - virtual_link_right: - [right, virtual_link_right] node_templates: right: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 1 requirements: - virtual_link_right: - virtual_binding: VDU-B-2 + - virtual_binding: VDU-B management: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 0 requirements: - virtual_link_management: - virtual_binding: VDU-B-1 + - virtual_binding: VDU-B left: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 2 requirements: - virtual_link_left: - virtual_binding: VDU-B-1 - internal_vl: - type: "tosca.nodes.nfv.VnfVirtualLink" - properties: - connectivity_type: - layer_protocols: [ ipv4 ] - description: Internal Virtual link in the VNF - vl_profile: - max_bitrate_requirements: - root: 100000 - leaf: 20000 - min_bitrate_requirements: - root: 10000 - leaf: 10000 - internal_vdu_b_1_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 2 - requirements: - - virtual_binding: VDU-B-1 - - virtual_link: internal_vl - internal_vdu_b_2_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 0 - requirements: - - virtual_binding: VDU-B-2 - - virtual_link: internal_vl - vdu_b_1_vsd: + - virtual_binding: VDU-B + vdu-b-1-vsd: type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" properties: virtual_block_storage_data: - size_of_storage: 20 + size_of_storage: 20 GB rdma_enabled: false sw_image_data: name: "vdu-b-1 image" @@ -76,63 +117,15 @@ topology_template: algorithm: "sha-224" hash: "somehashfortst010" container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' + disk_format: qcow2 + min_disk: '1' + min_ram: '2' size: '1' - artifacts: - sw_image: - type: "tosca.artifacts.nfv.SwImage" - file: vdu-b-1.qcow2 - vdu_b_2_vsd: - type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" - properties: - virtual_block_storage_data: - size_of_storage: 20 - rdma_enabled: false - sw_image_data: - name: "vdu-b-2 image" - version: "1.1" - checksum: - algorithm: "sha-224" - hash: "somehashfortst010" - container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' - size: '1' - artifacts: - sw_image: - type: tosca.artifacts.nfv.SwImage - file: vdu-b-2.qcow2 - vnf_b_1_VNF: - type: "tosca.nodes.nfv.VNF" - properties: - descriptor_id: "VNF-B-2VDUs" - descriptor_version: "2.0" - provider: "ETSI TST WG" - product_name: "VNF-B-2VDUs" - software_version: "2.0" - product_info_name: "VNF-B-2VDUs" - product_info_description: "TST010 reference VNF-B with 2 VDUs" - flavour_id: "VNF-B-2VDU_flavor" - flavour_description: "VNF-B with 2 VDUs flavor" - vnfm_info: - etsivnfm: - - v2.3.1 - interfaces: - Vnflcm: - scale: - implementation: scale-example.yaml - terminate: - implementation: terminate-example.yaml - operate: - implementation: operate-example.yaml - VDU_B_1: + VDU-B: type: "tosca.nodes.nfv.Vdu.Compute" properties: name: "vdu-b-1-vcd" - descriptor: "Description of VDU-B-1" + description: "Description of VDU-B-1" vdu_profile: min_number_of_instances: 1 max_number_of_instances: 2 @@ -140,29 +133,33 @@ topology_template: virtual_compute: properties: virtual_memory: - virtual_mem_size: 4096 + virtual_mem_size: 4096 MB numa_enabled: false virtual_cpu: num_virtual_cpu: 2 requirements: - virtual_storage: - - "vdu-b-1-vsd" - VDU_B_2: - type: "tosca.nodes.nfv.Vdu.Compute" + - virtual_storage: vdu-b-1-vsd + + vnf-b-1_VNF: + type: "tst010.vnf.simple" properties: - name: "vdu-b-2-vcd" - descriptor: "Description of VDU-B-2" - vdu_profile: - min_number_of_instances: 1 - max_number_of_instances: 4 - capabilities: - virtual_compute: - properties: - virtual_memory: - virtual_mem_size: 6144 - numa_enabled: false - virtual_cpu: - num_virtual_cpu: 2 - requirements: - virtual_storage: - - "vdu-b-2-vsd" \ No newline at end of file + descriptor_id: "VNF-B" + descriptor_version: "2.0" + provider: "ETSI TST WG" + product_name: "VDU_VNF-B" + software_version: "2.0" + product_info_name: "VDU_VNF-B" + product_info_description: "TST010 reference VNF-A" + flavour_id: "VNF-B_flavor" + flavour_description: "VNF-B flavor" + vnfm_info: + - etsivnfm:v2.3.1 + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + implementation: scale-example.yaml + terminate: + implementation: terminate-example.yaml + operate: + implementation: operate-example.yaml \ No newline at end of file diff --git a/SOL003/VNFPackageManagement-API/environment/variables.txt b/SOL003/VNFPackageManagement-API/environment/variables.txt index 0f3ab14e5..367da1ee0 100644 --- a/SOL003/VNFPackageManagement-API/environment/variables.txt +++ b/SOL003/VNFPackageManagement-API/environment/variables.txt @@ -95,9 +95,26 @@ ${callbackResp} localhost ${descriptorType} SOL001 ${check_descriptors} 1 +#############internal variables used for descriptor parsing################ +${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute +${tosca_type_VNF} tosca.nodes.nfv.VNF +${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink +${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp +${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage +${tosca_type_derived_from_VNF} + +${VDU_IDs} +${VNF_IDs} +${virtualLink_IDs} +${CP_IDs} +${Storage_IDs} +${internalCP_IDs} +${externalCP_IDs} +${InstantiationLevel_IDs} + ${Descriptor_ID} ${Provider} ${Product_Name} ${Software_Version} ${Descriptor_Version} -${Flavour_ID} +${Flavour_ID} \ No newline at end of file -- GitLab From 15fc587b9387e9a2db34a70e2299bdd7717c5a1f Mon Sep 17 00:00:00 2001 From: muhammadh Date: Tue, 28 Sep 2021 14:34:24 +0500 Subject: [PATCH 11/15] fixed VNFD parsing in SOL005 APIs --- .../NSLCMOperationKeywords.robot | 23 +- .../descriptors/SOL001/VNFD/vnfd_SOL001.yaml | 221 +++++++++--------- .../environment/variables.txt | 3 +- .../VNFPackageManagementKeywords.robot | 111 ++++++++- .../descriptors/SOL001/VNFD/vnfd_SOL001.yaml | 221 +++++++++--------- .../environment/variables.txt | 2 + 6 files changed, 341 insertions(+), 240 deletions(-) diff --git a/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot b/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot index 446f6ba0f..07deef4a1 100644 --- a/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot +++ b/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot @@ -247,8 +247,17 @@ Fetch Information from SOL001 descriptor file @{VirtualLink_labels}= Create List @{CP_labels}= Create List @{Storage_labels}= Create List + + FOR ${key} IN @{node_types.keys()} + ${node_type}= Get Variable Value ${node_types['${key}']['derived_from']} + ${is_VNF}= Run Keyword And Return Status Should Be Equal As Strings ${node_type} ${tosca_type_VNF} + Run Keyword If ${is_VNF} Set Global Variable ${tosca_type_derived_from_VNF} ${key} + END + ${derived_type_is_used}= Run Keyword And Return Status Should not be empty ${tosca_type_derived_from_VNF} + Run Keyword If ${derived_type_is_used} Set Global Variable ${tosca_type_VNF} ${tosca_type_derived_from_VNF} + FOR ${key} IN @{topology_template.node_templates.keys()} - ${key_type}= Get Variable Value ${topology_template.node_templates.${key}.type} + ${key_type}= Get Variable Value ${topology_template.node_templates['${key}'].type} ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} ${VNF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VNF} ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} @@ -270,12 +279,12 @@ Fetch Information from SOL001 descriptor file Get VNF Attributes from SOL001 [Arguments] ${VNF_label} Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - ${descriptor_id}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.descriptor_id} - ${provider}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.provider} - ${product_name}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.product_name} - ${software_version}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.software_version} - ${descriptor_version}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.descriptor_version} - ${flavour_id}= Get Variable Value ${topology_template.node_templates.${VNF_label}.properties.flavour_id} + ${descriptor_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_id} + ${provider}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.provider} + ${product_name}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.product_name} + ${software_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.software_version} + ${descriptor_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_version} + ${flavour_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.flavour_id} Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} diff --git a/SOL005/NSLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml b/SOL005/NSLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml index 3a90f45bf..838bea448 100644 --- a/SOL005/NSLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml +++ b/SOL005/NSLifecycleManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml @@ -1,73 +1,114 @@ tosca_definitions_version: tosca_simple_yaml_1_2 description: "TST010 reference VNF-B" + +imports: + - https://forge.etsi.org/rep/nfv/SOL001/raw/v3.3.1/etsi_nfv_sol001_vnfd_types.yaml + metadata: descriptor_id: "VNF-B" vendor: "ETSI TST WG" version: "2.0" + +node_types: + tst010.vnf.simple: + derived_from: tosca.nodes.nfv.VNF + properties: + descriptor_id: + type: string + default: VNF-B + descriptor_version: + type: string + default: '1.0' + provider: + type: string + default: ETSI TST WG + product_name: + type: string + default: VNF-B + software_version: + type: string + default: '1.0' + product_info_name: + type: string + default: VNF-B + product_info_description: + type: string + default: TST010 reference VNF-B + flavour_id: + type: string + default: VNF-B_flavor + flavour_description: + type: string + default: "VNF-B flavor" + vnfm_info: + type: list + entry_schema: + type: string + default: [ 'etsivnfm:v2.3.1' ] + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + description: Invoked upon receipt of a Scale VNF request + terminate: + description: Invoked upon receipt Terminate VNF request + operate: + description: Invoked upon receipt of an Operate VNF request + requirements: + - virtual_link_right: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_left: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_management: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 0] + topology_template: substitution_mappings: - node_type: "tosca.nodes.nfv.VNF" + node_type: "tst010.vnf.simple" requirements: + virtual_link_right: + [right, virtual_link_right] virtual_link_management: [management, virtual_link_management] virtual_link_left: [left, virtual_link_left] - virtual_link_right: - [right, virtual_link_right] node_templates: right: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 1 requirements: - virtual_link_right: - virtual_binding: VDU-B-2 + - virtual_binding: VDU-B management: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 0 requirements: - virtual_link_management: - virtual_binding: VDU-B-1 + - virtual_binding: VDU-B left: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 2 requirements: - virtual_link_left: - virtual_binding: VDU-B-1 - internal_vl: - type: "tosca.nodes.nfv.VnfVirtualLink" - properties: - connectivity_type: - layer_protocols: [ ipv4 ] - description: Internal Virtual link in the VNF - vl_profile: - max_bitrate_requirements: - root: 100000 - leaf: 20000 - min_bitrate_requirements: - root: 10000 - leaf: 10000 - internal_vdu_b_1_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 2 - requirements: - - virtual_binding: VDU-B-1 - - virtual_link: internal_vl - internal_vdu_b_2_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 0 - requirements: - - virtual_binding: VDU-B-2 - - virtual_link: internal_vl - vdu_b_1_vsd: + - virtual_binding: VDU-B + vdu-b-1-vsd: type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" properties: virtual_block_storage_data: - size_of_storage: 20 + size_of_storage: 20 GB rdma_enabled: false sw_image_data: name: "vdu-b-1 image" @@ -76,63 +117,15 @@ topology_template: algorithm: "sha-224" hash: "somehashfortst010" container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' + disk_format: qcow2 + min_disk: '1' + min_ram: '2' size: '1' - artifacts: - sw_image: - type: "tosca.artifacts.nfv.SwImage" - file: vdu-b-1.qcow2 - vdu_b_2_vsd: - type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" - properties: - virtual_block_storage_data: - size_of_storage: 20 - rdma_enabled: false - sw_image_data: - name: "vdu-b-2 image" - version: "1.1" - checksum: - algorithm: "sha-224" - hash: "somehashfortst010" - container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' - size: '1' - artifacts: - sw_image: - type: tosca.artifacts.nfv.SwImage - file: vdu-b-2.qcow2 - VNF_B: - type: "tosca.nodes.nfv.VNF" - properties: - descriptor_id: "VNF_B" - descriptor_version: "2.0" - provider: "ETSI TST WG" - product_name: "VNF-B-2VDUs" - software_version: "2.0" - product_info_name: "VNF-B-2VDUs" - product_info_description: "TST010 reference VNF-B with 2 VDUs" - flavour_id: "VNF-B-2VDU_flavor" - flavour_description: "VNF-B with 2 VDUs flavor" - vnfm_info: - etsivnfm: - - v2.3.1 - interfaces: - Vnflcm: - scale: - implementation: scale-example.yaml - terminate: - implementation: terminate-example.yaml - operate: - implementation: operate-example.yaml - VDU_B_1: + VDU-B: type: "tosca.nodes.nfv.Vdu.Compute" properties: name: "vdu-b-1-vcd" - descriptor: "Description of VDU-B-1" + description: "Description of VDU-B-1" vdu_profile: min_number_of_instances: 1 max_number_of_instances: 2 @@ -140,29 +133,33 @@ topology_template: virtual_compute: properties: virtual_memory: - virtual_mem_size: 4096 + virtual_mem_size: 4096 MB numa_enabled: false virtual_cpu: num_virtual_cpu: 2 requirements: - virtual_storage: - - "vdu-b-1-vsd" - VDU_B_2: - type: "tosca.nodes.nfv.Vdu.Compute" + - virtual_storage: vdu-b-1-vsd + + vnf-b-1_VNF: + type: "tst010.vnf.simple" properties: - name: "vdu-b-2-vcd" - descriptor: "Description of VDU-B-2" - vdu_profile: - min_number_of_instances: 1 - max_number_of_instances: 4 - capabilities: - virtual_compute: - properties: - virtual_memory: - virtual_mem_size: 6144 - numa_enabled: false - virtual_cpu: - num_virtual_cpu: 2 - requirements: - virtual_storage: - - "vdu-b-2-vsd" \ No newline at end of file + descriptor_id: "VNF-B" + descriptor_version: "2.0" + provider: "ETSI TST WG" + product_name: "VDU_VNF-B" + software_version: "2.0" + product_info_name: "VDU_VNF-B" + product_info_description: "TST010 reference VNF-A" + flavour_id: "VNF-B_flavor" + flavour_description: "VNF-B flavor" + vnfm_info: + - etsivnfm:v2.3.1 + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + implementation: scale-example.yaml + terminate: + implementation: terminate-example.yaml + operate: + implementation: operate-example.yaml \ No newline at end of file diff --git a/SOL005/NSLifecycleManagement-API/environment/variables.txt b/SOL005/NSLifecycleManagement-API/environment/variables.txt index ca2f36fe8..7e11084e3 100644 --- a/SOL005/NSLifecycleManagement-API/environment/variables.txt +++ b/SOL005/NSLifecycleManagement-API/environment/variables.txt @@ -101,11 +101,13 @@ ${callbackResp} 127.0.0.1 ${check_descriptors} 1 ${descriptorType} SOL006 +#############internal variables used for descriptor parsing################ ${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute ${tosca_type_VNF} tosca.nodes.nfv.VNF ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage +${tosca_type_derived_from_VNF} ${tosca_type_NS} tosca.nodes.nfv.NS ${tosca_type_NsVirtualLink} tosca.nodes.nfv.NsVirtualLink @@ -130,7 +132,6 @@ ${NS_Name} ${NS_Version} ${NS_InvariantId} - ${Descriptor_ID} ${Provider} ${Product_Name} diff --git a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index e4661c100..1f07d88e9 100644 --- a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -197,11 +197,46 @@ PARSE the Descriptor File Fetch Information from SOL001 descriptor file Import Variables ${CURDIR}/descriptors/SOL001/VNFD/vnfd_SOL001.yaml - ${descriptor_id}= Get Variable Value ${topology_template.node_templates.properties.descriptor_id} - ${provider}= Get Variable Value ${topology_template.node_templates.properties.provider} - ${product_name}= Get Variable Value ${topology_template.node_templates.properties.product_name} - ${software_version}= Get Variable Value ${topology_template.node_templates.properties.software_version} - ${descriptor_version}= Get Variable Value ${topology_template.node_templates.properties.descriptor_version} + @{VDU_labels}= Create List + @{VNF_labels}= Create List + @{VirtualLink_labels}= Create List + @{CP_labels}= Create List + @{Storage_labels}= Create List + FOR ${key} IN @{node_types.keys()} + ${node_type}= Get Variable Value ${node_types['${key}']['derived_from']} + ${is_VNF}= Run Keyword And Return Status Should Be Equal As Strings ${node_type} ${tosca_type_VNF} + Run Keyword If ${is_VNF} Set Global Variable ${tosca_type_derived_from_VNF} ${key} + END + ${derived_type_is_used}= Run Keyword And Return Status Should not be empty ${tosca_type_derived_from_VNF} + Run Keyword If ${derived_type_is_used} Set Global Variable ${tosca_type_VNF} ${tosca_type_derived_from_VNF} + FOR ${key} IN @{topology_template.node_templates.keys()} + ${key_type}= Get Variable Value ${topology_template.node_templates['${key}'].type} + ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_compute} + ${VNF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VNF} + ${Link_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_virtual_link} + ${VDUcp_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_VDU_cp} + ${Storage_check}= Run Keyword And Return Status Should Be Equal As Strings ${key_type} ${tosca_type_storage} + Run Keyword If ${VDU_check} Append To List ${VDU_labels} ${key} + Run Keyword If ${VNF_check} Append To List ${VNF_labels} ${key} + Run Keyword If ${VNF_check} Get VNF Attributes from SOL001 ${key} + Run Keyword If ${Link_check} Append To List ${VirtualLink_labels} ${key} + Run Keyword If ${VDUcp_check} Append To List ${CP_labels} ${key} + Run Keyword If ${Storage_check} Append To List ${Storage_labels} ${key} + END + Set Global Variable @{VDU_IDs} @{VDU_labels} + Set Global Variable @{VNF_IDs} @{VNF_labels} + Set Global Variable @{VirtualLink_IDs} @{VirtualLink_labels} + Set Global Variable @{CP_IDs} @{CP_labels} + Set Global Variable @{Storage_IDs} @{Storage_labels} + +Get VNF Attributes from SOL001 + [Arguments] ${VNF_label} + ${descriptor_id}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_id} + ${provider}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.provider} + ${product_name}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.product_name} + ${software_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.software_version} + ${descriptor_version}= Get Variable Value ${topology_template.node_templates['${VNF_label}'].properties.descriptor_version} + Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} @@ -213,15 +248,75 @@ Fetch Information from SOL006 descriptor file Import Variables ${CURDIR}/descriptors/SOL006/VNFD/vnfd_SOL006.yaml ${descriptor_id}= Get Variable Value ${nfv.vnfd[0].id} ${provider}= Get Variable Value ${nfv.vnfd[0].provider} - ${product_name}= Get Variable Value ${nfv.vnfd[0].product-name} - ${software_version}= Get Variable Value ${nfv.vnfd[0].software-version} - ${descriptor_version}= Get Variable Value ${nfv.vnfd[0].version} + ${product_name}= Get Variable Value ${nfv.vnfd[0]['product-name']} + ${software_version}= Get Variable Value ${nfv.vnfd[0]['software-version']} + ${descriptor_version}= Get Variable Value ${nfv.vnfd[0].version} + ${VDUcount}= Get Length ${nfv.vnfd[0].vdu} + ${extCP_count}= Get Length ${nfv.vnfd[0]['ext-cpd']} + ${virtualLink_count}= Get length ${nfv.vnfd[0]['int-virtual-link-desc']} + ${instantiation_levels}= Get Length ${nfv.vnfd[0].df['instantiation-level']} + FOR ${key} IN @{nfv.vnfd[0].keys()} + ${VDU_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} vdu + Run Keyword If ${VDU_check} Get VDU IDs ${VDUcount} + ${extCP_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} ext-cpd + Run Keyword If ${extCP_check} Get External CP IDs ${extCP_count} + ${virtualLink_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} int-virtual-link-desc + Run Keyword If ${virtualLink_check} Get Virtual Link IDs ${virtualLink_count} + ${DF_check}= Run Keyword And Return Status Should Be Equal As Strings ${key} df + Run Keyword If ${DF_check} Get Instantiation Levels ${instantiation_levels} + END + Set Global Variable ${Descriptor_ID} ${descriptor_id} Set Global Variable ${Provider} ${provider} Set Global Variable ${Product_Name} ${product_name} Set Global Variable ${Software_Version} ${software_version} Set Global Variable ${Descriptor_Version} ${descriptor_version} +Get VDU IDs + [Arguments] ${count} + @{VDU_labels}= Create List + ${Storage_labels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${VDU_labels} ${nfv.vnfd[0].vdu[${i}]['id']} + Append To List ${Storage_labels} ${nfv.vnfd[0].vdu[${i}]['virtual-storage-desc']} + Get Internal CPs for each VDU ${i} + END + Set Global Variable ${VDU_IDs} ${VDU_labels} + Set Global Variable ${Storage_IDs} ${Storage_labels} + +Get Internal CPs for each VDU + [Arguments] ${vdu} + ${count}= Get Length ${nfv.vnfd[0].vdu[${vdu}]['int-cpd']} + ${internal_CPs}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${internal_CPs} ${nfv.vnfd[0].vdu[${vdu}]['int-cpd'][${i}]['id']} + END + Set Global Variable ${internalCP_IDs} ${internal_CPs} + +Get External CP IDs + [Arguments] ${count} + @{external_CPs}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${external_CPs} ${nfv.vnfd[0]['ext-cpd'][${i}]['id']} + END + Set Global Variable ${externalCP_IDs} ${external_CPs} + +Get Virtual Link IDs + [Arguments] ${count} + ${VirtualLink_labels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${VirtualLink_labels} ${nfv.vnfd[0]['int-virtual-link-desc'][${i}]['id']} + END + Set Global Variable ${VirtualLink_IDs} ${VirtualLink_labels} + +Get Instantiation Levels + [Arguments] ${count} + @{Instantiation_Levels}= Create List + FOR ${i} IN RANGE ${count} + Append To List ${Instantiation_Levels} ${nfv.vnfd[0].df['instantiation-level'][${i}]['id']} + END + Set Global Variable ${InstantiationLevel_IDs} ${Instantiation_Levels} + Match the Response Attributes of vnfPkgInfo with Descriptors #Checking Response attributes with VNF Descriptors Should Be Equal As Strings ${response['body']['vnfdId']} ${Descriptor_Id} diff --git a/SOL005/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml b/SOL005/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml index e9159106a..603b1887d 100644 --- a/SOL005/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml +++ b/SOL005/VNFPackageManagement-API/descriptors/SOL001/VNFD/vnfd_SOL001.yaml @@ -1,73 +1,114 @@ tosca_definitions_version: tosca_simple_yaml_1_2 description: "TST010 reference VNF-B" + +imports: + - https://forge.etsi.org/rep/nfv/SOL001/raw/v3.3.1/etsi_nfv_sol001_vnfd_types.yaml + metadata: descriptor_id: "VNF-B" vendor: "ETSI TST WG" version: "2.0" + +node_types: + tst010.vnf.simple: + derived_from: tosca.nodes.nfv.VNF + properties: + descriptor_id: + type: string + default: VNF-B + descriptor_version: + type: string + default: '1.0' + provider: + type: string + default: ETSI TST WG + product_name: + type: string + default: VNF-B + software_version: + type: string + default: '1.0' + product_info_name: + type: string + default: VNF-B + product_info_description: + type: string + default: TST010 reference VNF-B + flavour_id: + type: string + default: VNF-B_flavor + flavour_description: + type: string + default: "VNF-B flavor" + vnfm_info: + type: list + entry_schema: + type: string + default: [ 'etsivnfm:v2.3.1' ] + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + description: Invoked upon receipt of a Scale VNF request + terminate: + description: Invoked upon receipt Terminate VNF request + operate: + description: Invoked upon receipt of an Operate VNF request + requirements: + - virtual_link_right: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_left: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link_management: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 1] + - virtual_link: + capability: tosca.capabilities.nfv.VirtualLinkable + relationship: tosca.relationships.nfv.VirtualLinksTo + occurrences: [0, 0] + topology_template: substitution_mappings: - node_type: "tosca.nodes.nfv.VNF" + node_type: "tst010.vnf.simple" requirements: + virtual_link_right: + [right, virtual_link_right] virtual_link_management: [management, virtual_link_management] virtual_link_left: [left, virtual_link_left] - virtual_link_right: - [right, virtual_link_right] node_templates: right: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 1 requirements: - virtual_link_right: - virtual_binding: VDU-B-2 + - virtual_binding: VDU-B management: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 0 requirements: - virtual_link_management: - virtual_binding: VDU-B-1 + - virtual_binding: VDU-B left: type: "tosca.nodes.nfv.VduCp" properties: + layer_protocols: [ ipv4 ] order: 2 requirements: - virtual_link_left: - virtual_binding: VDU-B-1 - internal_vl: - type: "tosca.nodes.nfv.VnfVirtualLink" - properties: - connectivity_type: - layer_protocols: [ ipv4 ] - description: Internal Virtual link in the VNF - vl_profile: - max_bitrate_requirements: - root: 100000 - leaf: 20000 - min_bitrate_requirements: - root: 10000 - leaf: 10000 - internal_vdu_b_1_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 2 - requirements: - - virtual_binding: VDU-B-1 - - virtual_link: internal_vl - internal_vdu_b_2_cp: - type: "tosca.nodes.nfv.VduCp" - properties: - order: 0 - requirements: - - virtual_binding: VDU-B-2 - - virtual_link: internal_vl - vdu_b_1_vsd: + - virtual_binding: VDU-B + vdu-b-1-vsd: type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" properties: virtual_block_storage_data: - size_of_storage: 20 + size_of_storage: 20 GB rdma_enabled: false sw_image_data: name: "vdu-b-1 image" @@ -76,63 +117,15 @@ topology_template: algorithm: "sha-224" hash: "somehashfortst010" container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' + disk_format: qcow2 + min_disk: '1' + min_ram: '2' size: '1' - artifacts: - sw_image: - type: "tosca.artifacts.nfv.SwImage" - file: vdu-b-1.qcow2 - vdu_b_2_vsd: - type: "tosca.nodes.nfv.Vdu.VirtualBlockStorage" - properties: - virtual_block_storage_data: - size_of_storage: 20 - rdma_enabled: false - sw_image_data: - name: "vdu-b-2 image" - version: "1.1" - checksum: - algorithm: "sha-224" - hash: "somehashfortst010" - container_format: "bare" - disk-format: qcow2 - min-disk: '1' - min-ram: '2' - size: '1' - artifacts: - sw_image: - type: tosca.artifacts.nfv.SwImage - file: vdu-b-2.qcow2 - vnf_b_1_VNF: - type: "tosca.nodes.nfv.VNF" - properties: - descriptor_id: "VNF-B-2VDUs" - descriptor_version: "2.0" - provider: "ETSI TST WG" - product_name: "VNF-B-2VDUs" - software_version: "2.0" - product_info_name: "VNF-B-2VDUs" - product_info_description: "TST010 reference VNF-B with 2 VDUs" - flavour_id: "VNF-B-2VDU_flavor" - flavour_description: "VNF-B with 2 VDUs flavor" - vnfm_info: - etsivnfm: - - v2.3.1 - interfaces: - Vnflcm: - scale: - implementation: scale-example.yaml - terminate: - implementation: terminate-example.yaml - operate: - implementation: operate-example.yaml - VDU_B_1: + VDU-B: type: "tosca.nodes.nfv.Vdu.Compute" properties: name: "vdu-b-1-vcd" - descriptor: "Description of VDU-B-1" + description: "Description of VDU-B-1" vdu_profile: min_number_of_instances: 1 max_number_of_instances: 2 @@ -140,29 +133,33 @@ topology_template: virtual_compute: properties: virtual_memory: - virtual_mem_size: 4096 + virtual_mem_size: 4096 MB numa_enabled: false virtual_cpu: num_virtual_cpu: 2 requirements: - virtual_storage: - - "vdu-b-1-vsd" - VDU_B_2: - type: "tosca.nodes.nfv.Vdu.Compute" + - virtual_storage: vdu-b-1-vsd + + vnf-b-1_VNF: + type: "tst010.vnf.simple" properties: - name: "vdu-b-2-vcd" - descriptor: "Description of VDU-B-2" - vdu_profile: - min_number_of_instances: 1 - max_number_of_instances: 4 - capabilities: - virtual_compute: - properties: - virtual_memory: - virtual_mem_size: 6144 - numa_enabled: false - virtual_cpu: - num_virtual_cpu: 2 - requirements: - virtual_storage: - - "vdu-b-2-vsd" \ No newline at end of file + descriptor_id: "VNF-B" + descriptor_version: "2.0" + provider: "ETSI TST WG" + product_name: "VDU_VNF-B" + software_version: "2.0" + product_info_name: "VDU_VNF-B" + product_info_description: "TST010 reference VNF-A" + flavour_id: "VNF-B_flavor" + flavour_description: "VNF-B flavor" + vnfm_info: + - etsivnfm:v2.3.1 + interfaces: + Vnflcm: + type: "tosca.interfaces.nfv.Vnflcm" + scale: + implementation: scale-example.yaml + terminate: + implementation: terminate-example.yaml + operate: + implementation: operate-example.yaml \ No newline at end of file diff --git a/SOL005/VNFPackageManagement-API/environment/variables.txt b/SOL005/VNFPackageManagement-API/environment/variables.txt index af33fce8c..f2c1e1446 100644 --- a/SOL005/VNFPackageManagement-API/environment/variables.txt +++ b/SOL005/VNFPackageManagement-API/environment/variables.txt @@ -93,11 +93,13 @@ ${callbackResp} 127.0.0.1 ${check_descriptors} 1 ${descriptorType} SOL006 +#############internal variables used for descriptor parsing################ ${tosca_type_VDU_compute} tosca.nodes.nfv.Vdu.Compute ${tosca_type_VNF} tosca.nodes.nfv.VNF ${tosca_type_virtual_link} tosca.nodes.nfv.VnfVirtualLink ${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp ${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage +${tosca_type_derived_from_VNF} ${VDU_IDs} ${VNF_IDs} -- GitLab From 348539ebe82cf40c0961c6ef2e2421d18bd9e1f9 Mon Sep 17 00:00:00 2001 From: muhammadh Date: Tue, 28 Sep 2021 14:38:54 +0500 Subject: [PATCH 12/15] added some missing internal variables to be removed from TAP GUI --- internal_variables.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/internal_variables.txt b/internal_variables.txt index 5890a71c9..9838cae32 100644 --- a/internal_variables.txt +++ b/internal_variables.txt @@ -364,6 +364,14 @@ ${NS_InvariantId} #${tosca_type_VDU_cp} tosca.nodes.nfv.VduCp #${tosca_type_storage} tosca.nodes.nfv.Vdu.VirtualBlockStorage +${tosca_type_NS} tosca.nodes.nfv.NS +${tosca_type_NsVirtualLink} tosca.nodes.nfv.NsVirtualLink +${tosca_type_NsCP} tosca.nodes.nfv.Cp + +${NS_VirtualLink_IDs} +${NsCP_IDs} +${SAP_IDs} + #${VDU_IDs} #${VNF_IDs} #${virtualLink_IDs} -- GitLab From 0e3bb2dc7291ff4a6ccd4f893a8dc92a168e3058 Mon Sep 17 00:00:00 2001 From: Elian Kraja Date: Tue, 28 Sep 2021 15:58:52 +0200 Subject: [PATCH 13/15] Fix issue #193 --- SOL002/VNFFaultManagement-API/Subscriptions.robot | 2 +- .../VnfLcmOperationKeywords.robot | 6 +++--- .../VNFPerformanceManagementKeywords.robot | 4 ++-- .../VNFFaultManagement-API/FaultManagement-APIKeyword.robot | 6 +++--- SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot | 4 ++-- .../VnfLcmMntOperationKeywords.robot | 6 +++--- .../VNFPackageManagementKeywords.robot | 4 ++-- .../VRQANOperationKeywords.robot | 6 +++--- SOL005/NSDManagement-API/NSDManagementKeywords.robot | 4 ++-- SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot | 2 +- .../NSLifecycleManagement-API/NSLCMOperationKeywords.robot | 6 +++--- .../VNFPackageManagementKeywords.robot | 4 ++-- .../FaultManagement-APIKeyword.robot | 2 +- .../NFVMANOLogManagementKeywords.robot | 2 +- SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot | 2 +- .../NFVMANOCimKeywords.robot | 2 +- .../NSInstanceUsageNotificationKeywords.robot | 6 +++--- SOL011/NSInstanceUsageNotification-API/Subscriptions.robot | 1 - SOL012/PolicyManagement-API/PolicyManagementKeywords.robot | 4 ++-- SOL012/PolicyManagement-API/Subscriptions.robot | 1 - 20 files changed, 36 insertions(+), 38 deletions(-) diff --git a/SOL002/VNFFaultManagement-API/Subscriptions.robot b/SOL002/VNFFaultManagement-API/Subscriptions.robot index 9e6d937f2..a88d02981 100644 --- a/SOL002/VNFFaultManagement-API/Subscriptions.robot +++ b/SOL002/VNFFaultManagement-API/Subscriptions.robot @@ -320,7 +320,7 @@ Post Create subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} diff --git a/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot b/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot index 45395980a..a3cb7f143 100644 --- a/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot +++ b/SOL002/VNFLifecycleManagement-API/VnfLcmOperationKeywords.robot @@ -1168,7 +1168,7 @@ Post Create subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -1187,7 +1187,7 @@ Post Create subscription - DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -1205,7 +1205,7 @@ Post Create subscription - NO-DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} diff --git a/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot b/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot index f986bff12..8651f5c8e 100644 --- a/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot +++ b/SOL002/VNFPerformanceManagement-API/VNFPerformanceManagementKeywords.robot @@ -106,7 +106,7 @@ Send Post Request for VNF Performance Subscription Set headers {"Accept": "${ACCEPT_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} ${body_request}= Get File jsons/subscriptions.json - POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body_request} + POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body_request} allow_redirects=false ${output}= Output response Set Suite Variable ${response} ${output} Run Keyword If ${VNFM_CHECKS_NOTIF_ENDPOINT} == 1 @@ -137,7 +137,7 @@ Send Post Request for Duplicated VNF Performance Subscription Set headers {"Accept": "${ACCEPT_JSON}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} ${body_request}= Get File jsons/subscriptions.json - POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body_request} + POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body_request} allow_redirects=false ${output}= Output response Set Suite Variable ${response} ${output} # Integer response status 303 diff --git a/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot b/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot index 896533beb..66ac5df09 100644 --- a/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot +++ b/SOL003/VNFFaultManagement-API/FaultManagement-APIKeyword.robot @@ -275,7 +275,7 @@ POST Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -293,7 +293,7 @@ Send POST Request for duplicated subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -311,7 +311,7 @@ Send POST Request for duplicated subscription not permitted &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} diff --git a/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot b/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot index adadcbcc8..8d764cab5 100644 --- a/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot +++ b/SOL003/VNFIndicator-API/VNFIndicatorsKeywords.robot @@ -106,7 +106,7 @@ Send Post Request for VNF Indicator Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} @@ -127,7 +127,7 @@ Send Post Request for Duplicated VNF indicator Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} diff --git a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot index 7c2aed5f8..c9bb13f01 100644 --- a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot +++ b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot @@ -1254,7 +1254,7 @@ Post Create subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -1274,7 +1274,7 @@ Post Create subscription - DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -1294,7 +1294,7 @@ Post Create subscription - NO-DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} diff --git a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index f2f5d6687..e2cf20f87 100644 --- a/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL003/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -418,7 +418,7 @@ Send Post Request for VNF Package Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} @@ -437,7 +437,7 @@ Send Post Request for Duplicated VNF Package Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} diff --git a/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot b/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot index 0e98e5e17..9c405cd24 100644 --- a/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot +++ b/SOL003/VirtualisedResourcesQuotaAvailableNotification-API/VRQANOperationKeywords.robot @@ -103,7 +103,7 @@ Send Post request for new Virtualised Resources Quota Available Notification sub &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -121,7 +121,7 @@ Send Post request for new Virtualised Resources Quota Available Notification sub &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -139,7 +139,7 @@ Send Post request for new Virtualised Resources Quota Available Notification sub &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} diff --git a/SOL005/NSDManagement-API/NSDManagementKeywords.robot b/SOL005/NSDManagement-API/NSDManagementKeywords.robot index 3e3fd76b3..e05cfa8b9 100644 --- a/SOL005/NSDManagement-API/NSDManagementKeywords.robot +++ b/SOL005/NSDManagement-API/NSDManagementKeywords.robot @@ -788,7 +788,7 @@ Send Post Request for NSD Management Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} @@ -809,7 +809,7 @@ Send POST Request for Duplicated NSD Management Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} diff --git a/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot b/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot index be49a99aa..939ddbeeb 100644 --- a/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot +++ b/SOL005/NSFaultManagement-API/NSFMOperationKeywords.robot @@ -222,7 +222,7 @@ POST Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} diff --git a/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot b/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot index 07deef4a1..3fd36dfce 100644 --- a/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot +++ b/SOL005/NSLifecycleManagement-API/NSLCMOperationKeywords.robot @@ -1138,7 +1138,7 @@ POST subscriptions &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -1157,7 +1157,7 @@ POST subscriptions DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -1176,7 +1176,7 @@ POST subscriptions NO DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} diff --git a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot index 1f07d88e9..661f409bb 100644 --- a/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot +++ b/SOL005/VNFPackageManagement-API/VNFPackageManagementKeywords.robot @@ -842,7 +842,7 @@ Send Post Request for VNF Package Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} @@ -861,7 +861,7 @@ Send Post Request for Duplicated VNF Package Subscription &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Global Variable ${response} ${output} Clear Requests ${callback_endpoint} diff --git a/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot b/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot index 7b776100f..66a272224 100644 --- a/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot +++ b/SOL009/NFVMANOFaultManagement-API/FaultManagement-APIKeyword.robot @@ -222,7 +222,7 @@ POST Subscription Duplication not permitted Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} ${template}= Get File jsons/fmSubscriptionRequest.json ${body}= Format String ${template} callback_uri=${callback_uri} callback_endpoint=${callback_endpoint} - Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable @{response} ${outputResponse} diff --git a/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot b/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot index cb971a90d..e1be24d63 100644 --- a/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot +++ b/SOL009/NFVMANOLogManagement-API/NFVMANOLogManagementKeywords.robot @@ -474,7 +474,7 @@ Send Post Request for Duplicated Subscription Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} ${template}= Get File jsons/subscriptions.json ${body}= Format String ${template} callback_uri=${callback_uri} callback_endpoint=${callback_endpoint} - POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Suite Variable ${response} ${output} diff --git a/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot b/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot index e1185af35..013db6210 100644 --- a/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot +++ b/SOL009/NFVMANOPerformanceManagement-API/Subscriptions.robot @@ -277,7 +277,7 @@ Send Post Request for Duplicated Performance Subscription Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": ${AUTHORIZATION}"} ${template}= Get File jsons/subscriptions.json ${body}= Format String ${template} callback_uri=${callback_uri} callback_endpoint=${callback_endpoint} - POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} + POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body} allow_redirects=false ${output}= Output response Set Suite Variable ${response} ${output} diff --git a/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot b/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot index 5657f95cb..44fb39106 100644 --- a/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot +++ b/SOL009/NFVManoConfigurationAndInformationManagement-API/NFVMANOCimKeywords.robot @@ -696,7 +696,7 @@ Send Post Request for Duplicated Subscription Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} ${template}= Get File jsons/CimSubscriptionRequest.json ${body_request}= Format String ${template} callback_uri=${callback_uri} callback_endpoint=${callback_endpoint} - POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body_request} + POST ${apiRoot}/${apiName}/${apiMajorVersion}/subscriptions ${body_request} allow_redirects=false ${output}= Output response Set Suite Variable ${response} ${output} diff --git a/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot b/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot index b72d95c96..87ccabc70 100644 --- a/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot +++ b/SOL011/NSInstanceUsageNotification-API/NSInstanceUsageNotificationKeywords.robot @@ -46,7 +46,7 @@ POST subscriptions Set Headers {"Content-Type": "${CONTENT_TYPE}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} ${body}= Get File jsons/NsInstanceUsageSubscriptionRequest.json - Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -57,7 +57,7 @@ POST subscriptions DUPLICATION Set Headers {"Content-Type": "${CONTENT_TYPE}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} ${body}= Get File jsons/NsInstanceUsageSubscriptionRequest.json - Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} @@ -68,7 +68,7 @@ POST subscriptions NO DUPLICATION Set Headers {"Content-Type": "${CONTENT_TYPE}"} Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} ${body}= Get File jsons/NsInstanceUsageSubscriptionRequest.json - Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} diff --git a/SOL011/NSInstanceUsageNotification-API/Subscriptions.robot b/SOL011/NSInstanceUsageNotification-API/Subscriptions.robot index 45b83dff1..7ad64adf5 100644 --- a/SOL011/NSInstanceUsageNotification-API/Subscriptions.robot +++ b/SOL011/NSInstanceUsageNotification-API/Subscriptions.robot @@ -49,7 +49,6 @@ POST Create a new Subscription - NO-DUPLICATION ... Applicability: Duplication NOT supported by NFVO-C ... Post-Conditions: Duplicate subscription is not created in the NFVO POST subscriptions NO DUPLICATION - Check Subscription Existence Check HTTP Response Status Code Is 303 Check HTTP Response Header Contains Location Check Postcondition Subscription Is Set diff --git a/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot b/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot index 3f760a7d8..b6fd1f0e8 100644 --- a/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot +++ b/SOL012/PolicyManagement-API/PolicyManagementKeywords.robot @@ -154,7 +154,7 @@ POST subscriptions &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} @@ -175,7 +175,7 @@ POST subscriptions NO DUPLICATION &{notification_response}= Create Mock Response status_code=204 Log Issue the subscription request Create Mock Expectation ${notification_request} ${notification_response} - Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} + Post ${apiRoot}/${apiName}/${apiVersion}/subscriptions ${body} allow_redirects=false ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} Clear Requests ${callback_endpoint} diff --git a/SOL012/PolicyManagement-API/Subscriptions.robot b/SOL012/PolicyManagement-API/Subscriptions.robot index 2e10d4b89..f0267cc12 100644 --- a/SOL012/PolicyManagement-API/Subscriptions.robot +++ b/SOL012/PolicyManagement-API/Subscriptions.robot @@ -31,7 +31,6 @@ POST Create a new Subscription - DUPLICATION NOT ALLOWED ... Applicability: Duplication is not supported by NFVMANO. ... Post-Conditions: Individual subscription resource returned in the location header is available. POST subscriptions NO DUPLICATION - Check Subscription Existence Check HTTP Response Status Code Is 303 Check HTTP Response Header Contains Location Check Postcondition Individual Subscription Resource Returned in Location Header Is Available -- GitLab From 0faa7460e9f2ea830008f75f4df8e0a2f592f840 Mon Sep 17 00:00:00 2001 From: Giacomo Bernini Date: Fri, 1 Oct 2021 11:42:03 +0200 Subject: [PATCH 14/15] fixed issue #194 in 3.3.1-fix-plu --- .../IndividualVNFInstance.robot | 2 +- .../VnfLcmMntOperationKeywords.robot | 25 ++++++++++++++++++- .../environment/variables.txt | 3 ++- 3 files changed, 27 insertions(+), 3 deletions(-) diff --git a/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot b/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot index 9baf42f52..423900cd7 100644 --- a/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot +++ b/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot @@ -84,7 +84,7 @@ PATCH Individual VNFInstance Conflict ... Config ID: Config_prod_VNFM ... Applicability: none ... Post-Conditions: VNFInstance not modified - PATCH individual vnfInstance + PATCH individual vnfInstance with conflict Check HTTP Response Status Code Is 409 Check HTTP Response Body Json Schema Is ProblemDetails diff --git a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot index c9bb13f01..a4bd5d49a 100644 --- a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot +++ b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot @@ -580,9 +580,31 @@ PATCH individual vnfInstance ${template}= Get File jsons/patchBodyRequest.json ${body}= Format String ${template} vnfdId=${Descriptor_ID} vnfdVersion= ${Descriptor_Version} Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_instances/${vnfInstanceId} ${body} + ${outputResponse}= Output response + Set Global Variable ${response} ${outputResponse} + +POST conflicting operation + Log Trying to create conflicting operation. + Set Headers {"Accept":"${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + ${template}= Get File jsons/terminateVnfRequest.json + ${body}= Format String ${template} terminationType=${terminationType} + Post ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_instances/${anotherInstantiatedVnfInstanceId}/terminate ${body} + +PATCH individual vnfInstance with conflict + POST conflicting operation + log Trying to modify an individual VNF instance with conflict + Set Headers {"Accept":"${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE_PATCH}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} + Run Keyword If ${check_descriptors} == 1 PARSE the Descriptor File + ${template}= Get File jsons/patchBodyRequest.json + ${body}= Format String ${template} vnfdId=${Descriptor_ID} vnfdVersion= ${Descriptor_Version} + Patch ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_instances/${anotherInstantiatedVnfInstanceId} ${body} ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} - + PATCH individual vnfInstance - Etag mismatch log Trying to modify an individual VNF instance Set Headers {"Accept":"${ACCEPT}"} @@ -603,6 +625,7 @@ DELETE individual vnfInstance Delete ${apiRoot}/${apiName}/${apiMajorVersion}/vnf_instances/${vnfInstanceId} ${outputResponse}= Output response Set Global Variable ${response} ${outputResponse} + DELETE individual vnfInstance in INSTANTIATED state log Trying to delete an individual VNF instance Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"${AUTHORIZATION_HEADER}":"${AUTHORIZATION_TOKEN}"} diff --git a/SOL003/VNFLifecycleManagement-API/environment/variables.txt b/SOL003/VNFLifecycleManagement-API/environment/variables.txt index 47b61bc5b..2c277829e 100644 --- a/SOL003/VNFLifecycleManagement-API/environment/variables.txt +++ b/SOL003/VNFLifecycleManagement-API/environment/variables.txt @@ -44,11 +44,12 @@ ${erroneousRange} bytes=10000000-1000000000 # Requesting a out of range nu ${full_length} 2000 #Full size of the content file to be transmitted using partial downloads ${instantiatedVnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f +${anotherInstantiatedVnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f ${notInstantiatedVnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f ${notExistingVnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f ${vnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f ${subscriptionId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f -${conflicVnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f +${conflictOperationVnfInstanceId} 6fc3539c-e602-4afa-8e13-962fb5a7d81f ${vnfInstanceId_NoSnapshotTask} no-snapshot-task-supported ${vnfSnapshotInfoId} ${vnfSnapshotInfoId_InUse} snapshotId-of-a-resource-AlreadyInUse-bySomeOther-operation -- GitLab From f24d1ff63fd0b09b3f735940ba04c0ef3d5e1d7e Mon Sep 17 00:00:00 2001 From: Elian Kraja Date: Tue, 5 Oct 2021 11:27:31 +0200 Subject: [PATCH 15/15] Update .jenkins.sh: Adding missing parameter to run-container script --- .jenkins.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.jenkins.sh b/.jenkins.sh index 8bfd08f3e..3fb76157c 100644 --- a/.jenkins.sh +++ b/.jenkins.sh @@ -18,7 +18,7 @@ if [ "$ret" != "0" ]; then exit -1 fi -bash ./scripts/run-container.sh "${run_dir}" +bash ./scripts/run-container.sh "${run_dir}" "$GIT_BRANCH" ret=$? if [ "$ret" != "0" ]; then echo "run-container.sh failed" -- GitLab