-
Notifications
You must be signed in to change notification settings - Fork 394
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Standardize VRF Regex for IOSXE show_vrf.py
Currently ShowVrf doesn't match all valid special characters in VRF names, and uses different regexes for different commands throughout show_vrf.py. This change standardizes the regexes to all be the same and matches the special characters.
- Loading branch information
Matt Childers
committed
Dec 9, 2023
1 parent
8ba274d
commit 188a94a
Showing
4 changed files
with
20 additions
and
4 deletions.
There are no files selected for viewing
6 changes: 6 additions & 0 deletions
6
changelog/undistributed/change_log_show_vrf_iosxe_20231209154701.rst
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
-------------------------------------------------------------------------------- | ||
Fix | ||
-------------------------------------------------------------------------------- | ||
* IOSXE | ||
* Modified ShowVrf: | ||
* Standardized VRF Matching to include special characters beyond dash and dot |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
src/genie/libs/parser/iosxe/tests/ShowVrf/cli/equal/golden_output_4_expected.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
expected_output = { | ||
"vrf": { | ||
"t!#$%()*+@^:t/<>,.~`'\";t": { | ||
"protocols": ["ipv4", "ipv6"], | ||
"route_distinguisher": "1:1" | ||
}, | ||
} | ||
} |
2 changes: 2 additions & 0 deletions
2
src/genie/libs/parser/iosxe/tests/ShowVrf/cli/equal/golden_output_4_output.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Name Default RD Protocols Interfaces | ||
t!#$%()*+@^:t/<>,.~`'";t 1:1 ipv4,ipv6 |