Refactor test_utils_rfc8040.py portmapping methods
[transportpce.git] / tests / transportpce_tests / 1.2.1 / test02_topo_portmapping.py
index 653ae84555ea42df5b59d77c6e953a74b3278a5c..1f902c3e734156edc490362fa9fc208df3f12b64 100644 (file)
@@ -57,12 +57,12 @@ class TransportPCEtesting(unittest.TestCase):
         for node in resTopo['network'][0]['node']:
             nodeId = node['node-id']
             nodeMapId = nodeId.split("-")[0]
-            response = test_utils_rfc8040.get_portmapping_node_info(nodeMapId)
+            response = test_utils_rfc8040.get_portmapping_node_attr(nodeMapId, "node-info", None)
             self.assertEqual(response['status_code'], requests.codes.ok)
             for tp in node['ietf-network-topology:termination-point']:
                 tpId = tp['tp-id']
                 if (not "CP" in tpId) and (not "CTP" in tpId):
-                    response2 = test_utils_rfc8040.portmapping_request(nodeMapId, tpId)
+                    response2 = test_utils_rfc8040.get_portmapping_node_attr(nodeMapId, "mapping", tpId)
                     self.assertEqual(response2['status_code'], requests.codes.ok)
 
     # Disconnect the ROADMA