Due to the format change in the message queue caused by the SDK change, the function... 88/130288/1
authorzhaoyh6 <zhaoyh6@asiainfo.com>
Tue, 16 Aug 2022 03:00:43 +0000 (11:00 +0800)
committerzhaoyh6 <zhaoyh6@asiainfo.com>
Tue, 16 Aug 2022 03:00:52 +0000 (11:00 +0800)
Issue-ID: DCAEGEN2-3157
Signed-off-by: zhaoyh6 <zhaoyh6@asiainfo.com>
Change-Id: I0a1cf8ba5b6c1278bec360e6e54bc57ccb3c8613

tests/dcaegen2-services-slice-analysis-ms/testcases/slice-analysis-ms-test-aai-dcae.robot

index f0e8029..7e27ae4 100644 (file)
@@ -50,6 +50,7 @@ Verify periodic checking from dmaap
         ${expected_payload}=    Evaluate     json.loads("""${expected_string}""")     json
         ${result}=  Convert To String  ${result.content}
         ${result_string}=    Get Substring    ${result}  2    -2
+        ${result_string}=    RemoveExtraByte    ${result_string}
         ${actual_data}=      Evaluate     json.loads("""${result_string}""")     json
         ${actual_payload_str}=    Set Variable     ${actual_data['payload']}
         ${actual_payload}=       Evaluate     json.loads("""${actual_payload_str}""")     json
@@ -86,6 +87,7 @@ Verify ccvpn modification from dmaap
         ${expected_payload}=    Evaluate     json.loads("""${expected_string}""")     json
         ${result}=  Convert To String  ${result.content}
         ${result_string}=    Get Substring    ${result}  2    -2
+        ${result_string}=    RemoveExtraByte    ${result_string}
         ${actual_data}=      Evaluate     json.loads("""${result_string}""")     json
         ${actual_payload_str}=    Set Variable     ${actual_data['payload']}
         ${actual_payload}=       Evaluate     json.loads("""${actual_payload_str}""")     json
@@ -93,4 +95,12 @@ Verify ccvpn modification from dmaap
 
 *** Keywords ***
 Provided precondition
-    Setup system under test
\ No newline at end of file
+    Setup system under test
+
+RemoveExtraByte        
+    [Arguments]     ${result_string}
+    ${result_string}=    Get Substring     ${result_string}    2       -2
+    ${result_string}=    Replace String    ${result_string}    \\\"    \"
+    ${result_string}=    Replace String    ${result_string}    \\\\    \\
+    [Return]        ${result_string}
+