summaryrefslogtreecommitdiff
path: root/tests/topotests/ospf_basic_functionality/test_ospf_single_area.py
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@nvidia.com>2020-12-17 13:19:52 -0500
committerDonald Sharp <sharpd@nvidia.com>2020-12-17 13:19:52 -0500
commit9fd80543fe9ad6011b5e186cf09990a37fd42c85 (patch)
treec62cb6995e9667c58142113412c37dca3aa65999 /tests/topotests/ospf_basic_functionality/test_ospf_single_area.py
parent91653aefd487fb35ffca8f2d8db35b8c2b03fd6c (diff)
tests: unicode to frr_unicode
Let's standardize on the internal to frr unicode function. Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'tests/topotests/ospf_basic_functionality/test_ospf_single_area.py')
-rw-r--r--tests/topotests/ospf_basic_functionality/test_ospf_single_area.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/topotests/ospf_basic_functionality/test_ospf_single_area.py b/tests/topotests/ospf_basic_functionality/test_ospf_single_area.py
index 3a269d853c..b2b0fb8d44 100644
--- a/tests/topotests/ospf_basic_functionality/test_ospf_single_area.py
+++ b/tests/topotests/ospf_basic_functionality/test_ospf_single_area.py
@@ -29,6 +29,7 @@ import pytest
import json
from copy import deepcopy
from ipaddress import IPv4Address
+from lib.topotest import frr_unicode
# Save the Current Working Directory to find configuration files.
CWD = os.path.dirname(os.path.realpath(__file__))
@@ -233,7 +234,7 @@ def test_ospf_p2p_tc3_p0(request):
topo_modify_change_ip = deepcopy(topo)
intf_ip = topo_modify_change_ip["routers"]["r0"]["links"]["r3"]["ipv4"]
topo_modify_change_ip["routers"]["r0"]["links"]["r3"]["ipv4"] = str(
- IPv4Address(unicode(intf_ip.split("/")[0])) + 3
+ IPv4Address(frr_unicode(intf_ip.split("/")[0])) + 3
) + "/{}".format(intf_ip.split("/")[1])
build_config_from_json(tgen, topo_modify_change_ip, save_bkup=False)
@@ -284,7 +285,7 @@ def test_ospf_p2p_tc3_p0(request):
topo_modify_change_ip = deepcopy(topo)
intf_ip = topo_modify_change_ip["routers"]["r0"]["links"]["r3"]["ipv4"]
topo_modify_change_ip["routers"]["r0"]["links"]["r3"]["ipv4"] = str(
- IPv4Address(unicode(intf_ip.split("/")[0])) + 3
+ IPv4Address(frr_unicode(intf_ip.split("/")[0])) + 3
) + "/{}".format(int(intf_ip.split("/")[1]) + 1)
build_config_from_json(tgen, topo_modify_change_ip, save_bkup=False)