diff options
author | Christian Poessinger <christian@poessinger.com> | 2021-08-20 18:05:09 +0200 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2021-08-20 18:05:09 +0200 |
commit | fa51dafe4dcad975762cff3c390e400ca09af41a (patch) | |
tree | 50875484d1c5de76740c3be137f3c2115247c5a9 /smoketest/scripts/cli/base_vyostest_shim.py | |
parent | 0a8a0188033d6b27c521f082fdddae9873dd5d3d (diff) | |
download | vyos-1x-fa51dafe4dcad975762cff3c390e400ca09af41a.tar.gz vyos-1x-fa51dafe4dcad975762cff3c390e400ca09af41a.zip |
smoketest: bgp: add support to extract only given SAFI from FRR
Diffstat (limited to 'smoketest/scripts/cli/base_vyostest_shim.py')
-rw-r--r-- | smoketest/scripts/cli/base_vyostest_shim.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/smoketest/scripts/cli/base_vyostest_shim.py b/smoketest/scripts/cli/base_vyostest_shim.py index 419530c3d..50f80e7d1 100644 --- a/smoketest/scripts/cli/base_vyostest_shim.py +++ b/smoketest/scripts/cli/base_vyostest_shim.py @@ -76,9 +76,9 @@ class VyOSUnitTestSHIM: while run(f'sudo lsof | grep -q {commit_lock}') == 0: sleep(0.250) - def getFRRconfig(self, string, end='$', endsection='^!'): + def getFRRconfig(self, string, end='$', endsection='^!', daemon=''): """ Retrieve current "running configuration" from FRR """ - command = f'vtysh -c "show run" | sed -n "/^{string}{end}/,/{endsection}/p"' + command = f'vtysh -c "show run {daemon} no-header" | sed -n "/^{string}{end}/,/{endsection}/p"' out = cmd(command) if self.debug: import pprint |