[config] Update unit tests for static routes#1619
Closed
d-dashkov wants to merge 2 commits intosonic-net:masterfrom
Closed
[config] Update unit tests for static routes#1619d-dashkov wants to merge 2 commits intosonic-net:masterfrom
d-dashkov wants to merge 2 commits intosonic-net:masterfrom
Conversation
Signed-off-by: d-dashkov <[email protected]>
prsunny
reviewed
May 19, 2021
config/main.py
Outdated
| # If defined intf name, check if it belongs to interface | ||
| if 'ifname' in route: | ||
| if (not route['ifname'] in config_db.get_keys('VLAN_INTERFACE') and | ||
| if (not route['ifname'] in config_db.get_keys('VLAN') and |
Contributor
There was a problem hiding this comment.
This will break the assumption made as part of PR #1535 (comment)
Contributor
Author
There was a problem hiding this comment.
I see that this will allow configuring a route to ifname without ip, but this seems to be the only way to solve this problem.
Contributor
Author
|
retest this please |
Collaborator
|
@d-dashkov , @prsunny - What is the status with this PR ? Do you have plans to approve it ? |
Contributor
As mentioned, this poses another challenge in the delete flow. Hence, not planning to merge |
Signed-off-by: d-dashkov <[email protected]>
Contributor
Author
|
@prsunny could you check this PR, I returned the rules for vlan and just left a warning about a black hole |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What I did
Update unit tests with ethernet and vlan cases
Also solved #1534 (comment) with notifying the user.
How I did it
Add unit tests and add verification for blackhole
New command output (if the output of a command-line utility has changed)
If user trying to set blackhole on existing route
"Error: this route is already configured on nexthop, remove it before configuring to black hole"
Signed-off-by: d-dashkov [email protected]