]> git.puffer.fish Git - mirror/frr.git/commitdiff
tests: detect all daemons correctly when using frr.conf
authorJafar Al-Gharaibeh <jafar@atcorp.com>
Fri, 30 Aug 2024 19:35:31 +0000 (14:35 -0500)
committerDonald Sharp <donaldsharp72@gmail.com>
Wed, 12 Mar 2025 17:05:25 +0000 (13:05 -0400)
Signed-off-by: Jafar Al-Gharaibeh <jafar@atcorp.com>
tests/topotests/lib/topogen.py

index f49e30ea5f9ca3f9d52a8af445a33143ae82e1c6..7941e5c1d23337258aa7a475dab2cdc105db9f35 100644 (file)
@@ -832,10 +832,10 @@ class TopoRouter(TopoGear):
             for daemon in self.RD:
                 # This will not work for all daemons
                 daemonstr = self.RD.get(daemon).rstrip("d")
-                if daemonstr == "pim":
-                    grep_cmd = "grep 'ip {}' {}".format(daemonstr, source_path)
+                if daemonstr == "path":
+                    grep_cmd = "grep 'candidate-path' {}".format(source_path)
                 else:
-                    grep_cmd = "grep 'router {}' {}".format(daemonstr, source_path)
+                    grep_cmd = "grep -w '{}' {}".format(daemonstr, source_path)
                 result = self.run(grep_cmd, warn=False).strip()
                 if result:
                     self.load_config(daemon, "")