Fix failed tests 09/66909/1
authorMariusz Wagner <mariusz.wagner@nokia.com>
Mon, 17 Sep 2018 07:47:56 +0000 (09:47 +0200)
committerMariusz Wagner <mariusz.wagner@nokia.com>
Mon, 17 Sep 2018 07:47:56 +0000 (09:47 +0200)
Fixed 2 TC. Changed sourceName -> correlationId

Issue-ID: INT-661

Change-Id: Ic17f8b63c8ed2bb5ba0e9bfbb716dbc7f63a5686
Signed-off-by: Mariusz Wagner <mariusz.wagner@nokia.com>
test/csit/tests/dcaegen2/prh-testcases/resources/PrhLibrary.py

index 7c52f54..6a95c71 100644 (file)
@@ -23,16 +23,16 @@ class PrhLibrary(object):
         json_to_python = json.loads(json_file)
         ipv4 = json_to_python["event"]["pnfRegistrationFields"]["oamV4IpAddress"]
         ipv6 = json_to_python["event"]["pnfRegistrationFields"]["oamV6IpAddress"]
-        header = json_to_python["event"]["commonEventHeader"]["sourceName"]
-        str_json = '{"sourceName":"' + header + '","ipaddress-v4-oam":"' + ipv4 + '","ipaddress-v6-oam":"' + ipv6 + '"}'
+        correlationId = json_to_python["event"]["commonEventHeader"]["sourceName"]
+        str_json = '{"correlationId":"' + correlationId + '","ipaddress-v4-oam":"' + ipv4 + '","ipaddress-v6-oam":"' + ipv6 + '"}'
         python_to_json = json.dumps(str_json)
         return python_to_json.replace("\\", "")[1:-1]
 
     @staticmethod
     def create_pnf_name(json_file):
         json_to_python = json.loads(json_file)
-        header = json_to_python["event"]["commonEventHeader"]["sourceName"]
-        return header
+        correlationId = json_to_python["event"]["commonEventHeader"]["sourceName"]
+        return correlationId
 
     @staticmethod
     def stop_aai():