Fix bug in get_l2xc_interfaces(), and add tests for it

This commit is contained in:
Pim van Pelt
2022-03-22 13:15:21 +00:00
parent 7ae82c297c
commit 907412f49c
4 changed files with 32 additions and 5 deletions

View File

@ -22,7 +22,7 @@ def get_lcps(yaml):
if 'lcp' in iface:
ret.append(iface['lcp'])
if 'sub-interfaces' in iface:
for sub_ifname, sub_iface in iface['sub-interfaces'].items():
for subid, sub_iface in iface['sub-interfaces'].items():
if 'lcp' in sub_iface:
ret.append(sub_iface['lcp'])