From 5ccf1c2a7dbab281deef0b10e71afadc13ba1e5a Mon Sep 17 00:00:00 2001
From: root <root@DESKTOP-A5SJGL5.localdomain>
Date: Fri, 24 Jan 2020 13:07:37 +0500
Subject: [PATCH] bug-fixes

---
 .../IndividualVNFInstance.robot                      |  4 ++--
 .../ScaleVNFToLevelTask.robot                        |  2 +-
 .../TerminateVNFTask.robot                           |  2 +-
 .../VnfLcmMntOperationKeywords.robot                 | 12 ++++--------
 .../VNFLifecycleOperationGranting-API/Grants.robot   |  7 +++++--
 5 files changed, 13 insertions(+), 14 deletions(-)

diff --git a/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot b/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot
index 21b0a22a..9af273e2 100644
--- a/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot
+++ b/SOL003/VNFLifecycleManagement-API/IndividualVNFInstance.robot
@@ -66,7 +66,7 @@ PATCH Individual VNFInstance
 PATCH Individual VNFInstance Precondition failed
      [Documentation]    Test ID: 7.3.1.2.5
     ...    Test title: PATCH Individual VNFInstance Precondition failed
-    ...    Test objective: The objective is to test a PATCH request when Pre-condition given in HTTP request header failed due to ETag mismatch
+    ...    Test objective: The objective is to create a new VNF instance resource
     ...    Pre-conditions:  VNF Instance is already created (Test ID 7.3.1.2.2)
     ...    Reference: clause 5.4.3.3.4 - ETSI GS NFV-SOL 003 [1] v2.4.1
     ...    Config ID: Config_prod_VNFM
@@ -79,7 +79,7 @@ PATCH Individual VNFInstance Precondition failed
 PATCH Individual VNFInstance Conflict
      [Documentation]    Test ID: 7.3.1.2.6
     ...    Test title: PATCH Individual VNFInstance Conflict
-    ...    Test objective: The objective is to test the conflict while modifying a VNF instance resource because another LCM operation is ongoing
+    ...    Test objective: The objective is to test the conflict while modifying a VNF instance resource
     ...    Pre-conditions: another LCM operation is ongoing
     ...    Reference: clause 5.4.3.3.4 - ETSI GS NFV-SOL 003 [1] v2.4.1
     ...    Config ID: Config_prod_VNFM
diff --git a/SOL003/VNFLifecycleManagement-API/ScaleVNFToLevelTask.robot b/SOL003/VNFLifecycleManagement-API/ScaleVNFToLevelTask.robot
index 17db5612..021d5cee 100644
--- a/SOL003/VNFLifecycleManagement-API/ScaleVNFToLevelTask.robot
+++ b/SOL003/VNFLifecycleManagement-API/ScaleVNFToLevelTask.robot
@@ -12,7 +12,7 @@ POST Scale a vnfInstance to level
     [Documentation]    Test ID: 7.3.1.5.1
     ...    Test title: POST Scale a vnfInstance to level
     ...    Test objective: The objective is to scale a VNF instance to a target level.
-    ...    Pre-conditions: VNF is Instantiated
+    ...    Pre-conditions: VNF instance resource is in INSTANTIATED state
     ...    Reference: clause 5.4.6.3.1 - ETSI GS NFV-SOL 003 [1] v2.4.1
     ...    Config ID: Config_prod_VNFM
     ...    Applicability: 
diff --git a/SOL003/VNFLifecycleManagement-API/TerminateVNFTask.robot b/SOL003/VNFLifecycleManagement-API/TerminateVNFTask.robot
index fee74627..df4d0e2a 100644
--- a/SOL003/VNFLifecycleManagement-API/TerminateVNFTask.robot
+++ b/SOL003/VNFLifecycleManagement-API/TerminateVNFTask.robot
@@ -13,7 +13,7 @@ POST Terminate a vnfInstance
     [Documentation]    Test ID: 7.3.1.7.1
     ...    Test title: POST Terminate a vnfInstance
     ...    Test objective: The objective is to test that POST method terminate a VNF instance
-    ...    Pre-conditions: Resource state is INSTANTIATED
+    ...    Pre-conditions: Resource state should be INSTANTIATED
     ...    Reference: clause 5.4.8.3.1 - ETSI GS NFV-SOL 003 [1] v2.4.1
     ...    Config ID: Config_prod_VNFM
     ...    Applicability: none
diff --git a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot
index a1adf8ee..c245f0cc 100644
--- a/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot
+++ b/SOL003/VNFLifecycleManagement-API/VnfLcmMntOperationKeywords.robot
@@ -1148,11 +1148,7 @@ GET test endpoint
     Sleep  ${sleep_interval}
     Verify Mock Expectation  ${req}
     Clear Requests  ${callback_endpoint}    	 
-Verify Resources not Deleted  	
-    log    Trying to get information about an individual VNF instance
-    Set Headers    {"Accept":"${ACCEPT}"}  
-    Set Headers    {"Content-Type": "${CONTENT_TYPE}"}
-    Run Keyword If    ${AUTH_USAGE} == 1    Set Headers    {"Authorization":"${AUTHORIZATION}"}
-    Get    ${apiRoot}/${apiName}/${apiVersion}/vnf_instances/${response['body']['id']} 		
-    ${outputResponse}=    Output    response
-	Set Global Variable    @{response}    ${outputResponse}
\ No newline at end of file
+Verify Resources not Deleted  
+    GET multiple vnfInstances
+    Check HTTP Response Status Code Is    200
+    Check HTTP Response Body Json Schema Is    vnfInstances 	
diff --git a/SOL003/VNFLifecycleOperationGranting-API/Grants.robot b/SOL003/VNFLifecycleOperationGranting-API/Grants.robot
index 1dbba51e..6ecca096 100644
--- a/SOL003/VNFLifecycleOperationGranting-API/Grants.robot
+++ b/SOL003/VNFLifecycleOperationGranting-API/Grants.robot
@@ -46,9 +46,9 @@ Requests a grant for a particular VNF lifecycle operation - Asynchronous mode
 Requests a grant for a particular VNF lifecycle operation - Forbidden 
     [Documentation]    Test ID: 7.3.2.1.3
     ...    Test title: Requests a grant for a particular VNF lifecycle operation - Forbidden 
-    ...    Test objective: The objective is to request a grant for a particular VNF lifecycle operation and the grant is rejected
+    ...    Test objective: The objective is to request a grant for a particular VNF lifecycle operation and check the content of the problem details data structure returned
     ...    Pre-conditions: none
-    ...    Reference: clause 9.4.2.3.1 - ETSI GS NFV-SOL 003 [1] v2.4.1
+    ...    Reference: clause 9.4.2.3.2 - ETSI GS NFV-SOL 003 [1] v2.4.1
     ...    Config ID: Config_prod_NFVO
     ...    Applicability: none
     ...    Post-Conditions: none
@@ -178,6 +178,9 @@ Get an individual grant - Successful
     Get    ${response['headers']['Location']}
     Log    Validate Status code
     Integer    response status    200
+    ${result}    Output    response body
+    Validate Json    grant.schema.json    ${result}
+    Log    Validation OK
     
 Get Grants
     Log    Trying to perform a GET. This method should not be implemented
-- 
GitLab