From b48798b23a80531f3222b62dd20b60bd04babae1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mattias=20Walstr=C3=B6m?= Date: Thu, 11 Jan 2024 16:55:09 +0100 Subject: [PATCH] test: Set hostname for OSPF tests to detect the role --- test/case/ietf_routing/ospf_basic.py | 11 ++++++++++- test/case/ietf_routing/ospf_unnumbered_interface.py | 12 ++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/test/case/ietf_routing/ospf_basic.py b/test/case/ietf_routing/ospf_basic.py index 0b2cb702..6335c7c7 100755 --- a/test/case/ietf_routing/ospf_basic.py +++ b/test/case/ietf_routing/ospf_basic.py @@ -44,7 +44,11 @@ def config_target1(target, data, link): ] } }) - + target.put_config_dict("ietf-system", { + "system": { + "hostname": "R1" + } + }) target.put_config_dict("ietf-routing", { "routing": { "control-plane-protocols": { @@ -111,6 +115,11 @@ def config_target2(target, link): } }) + target.put_config_dict("ietf-system", { + "system": { + "hostname": "R2" + } + }) target.put_config_dict("ietf-routing", { "routing": { "control-plane-protocols": { diff --git a/test/case/ietf_routing/ospf_unnumbered_interface.py b/test/case/ietf_routing/ospf_unnumbered_interface.py index 1fbf8ba7..bd547691 100755 --- a/test/case/ietf_routing/ospf_unnumbered_interface.py +++ b/test/case/ietf_routing/ospf_unnumbered_interface.py @@ -48,6 +48,12 @@ def config_target1(target, data, link): ] } }) + target.put_config_dict("ietf-system", { + "system": { + "hostname": "R1" + } + }) + target.put_config_dict("ietf-routing", { "routing": { @@ -116,6 +122,12 @@ def config_target2(target, link): } }) + target.put_config_dict("ietf-system", { + "system": { + "hostname": "R2" + } + }) + target.put_config_dict("ietf-routing", { "routing": { "control-plane-protocols": {