-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tests: fix redistribute key in ospf tests #7837
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your contribution to FRR!
Click for style suggestions
To apply these suggestions:
curl -s https://gist.githubusercontent.com/polychaeta/b87d1fc725cb7949b077dcf02a10e597/raw/4bc514a91b326886f4a3021c506cc2a09a7d9c9c/cr_7837_1610116884.diff | git apply
diff --git a/tests/topotests/lib/common_config.py b/tests/topotests/lib/common_config.py
index 5bcf19cda..41185fed2 100644
--- a/tests/topotests/lib/common_config.py
+++ b/tests/topotests/lib/common_config.py
@@ -3065,7 +3065,11 @@ def verify_rib(
errormsg = (
"[DUT: {}]: tag value {}"
" is not matched for"
- " route {} in RIB \n".format(dut, _tag, st_rt,)
+ " route {} in RIB \n".format(
+ dut,
+ _tag,
+ st_rt,
+ )
)
return errormsg
@@ -3082,7 +3086,11 @@ def verify_rib(
errormsg = (
"[DUT: {}]: metric value "
"{} is not matched for "
- "route {} in RIB \n".format(dut, metric, st_rt,)
+ "route {} in RIB \n".format(
+ dut,
+ metric,
+ st_rt,
+ )
)
return errormsg
diff --git a/tests/topotests/lib/ospf.py b/tests/topotests/lib/ospf.py
index bbc7fb692..966c7f421 100644
--- a/tests/topotests/lib/ospf.py
+++ b/tests/topotests/lib/ospf.py
@@ -845,13 +845,17 @@ def verify_ospf_rib(
if "routeType" not in ospf_rib_json[st_rt]:
errormsg = (
"[DUT: {}]: routeType missing"
- " for route {} in OSPF RIB \n".format(dut, st_rt)
+ " for route {} in OSPF RIB \n".format(
+ dut, st_rt
+ )
)
return errormsg
elif _rtype != ospf_rib_json[st_rt]["routeType"]:
errormsg = (
"[DUT: {}]: routeType mismatch"
- " for route {} in OSPF RIB \n".format(dut, st_rt)
+ " for route {} in OSPF RIB \n".format(
+ dut, st_rt
+ )
)
return errormsg
else:
If you are a new contributor to FRR, please see our contributing guidelines.
After making changes, you do not need to create a new PR. You should perform an amend or interactive rebase followed by a force push.
@@ -216,6 +216,19 @@ def red_connected(dut, config=True): | |||
assert result is True, "Testcase: Failed \n Error: {}".format(result) | |||
|
|||
|
|||
def redistribute(dut, route_type, **kwargs): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we really need 6 different copies of the same function? Shouldn't this belong in lib/ospf.py?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, but as they originally were implemented in each test I thought of keeping like that.
As the function is part of the lib now, I renamed it redistribute_ospf
Outdated results 💚Basic BGPD CI results: SUCCESS, 0 tests failed
For details, please contact louberger |
Continuous Integration Result: FAILEDContinuous Integration Result: FAILEDSee below for issues. This is a comment from an automated CI system. Get source / Pull Request: SuccessfulBuilding Stage: SuccessfulBasic Tests: FailedTopo tests part 3 on Ubuntu 18.04 arm8: Failed (click for details)Topo tests part 3 on Ubuntu 18.04 arm8: No useful log foundTopo tests part 0 on Ubuntu 16.04 amd64: Failed (click for details)Topology Test Results are at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-TOPOU1604-16365/test Topology Tests failed for Topo tests part 0 on Ubuntu 16.04 amd64:
see full log at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-16365/artifact/TOPOU1604/ErrorLog/log_topotests.txt Topo tests part 2 on Ubuntu 16.04 i386: Failed (click for details)Topology Test Results are at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-TP2U1604I386-16365/test Topology Tests failed for Topo tests part 2 on Ubuntu 16.04 i386:
see full log at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-16365/artifact/TP2U1604I386/ErrorLog/log_topotests.txt Successful on other platforms/tests
Warnings Generated during build:Debian 10 amd64 build: Successful with additional warningsDebian Package lintian failed for Debian 10 amd64 build:
|
Continuous Integration Result: FAILEDContinuous Integration Result: FAILEDSee below for issues. This is a comment from an automated CI system. Get source / Pull Request: SuccessfulBuilding Stage: SuccessfulBasic Tests: FailedTopo tests part 3 on Ubuntu 18.04 arm8: Failed (click for details)Topo tests part 3 on Ubuntu 18.04 arm8: No useful log foundTopo tests part 2 on Ubuntu 18.04 amd64: Failed (click for details)Topology Test Results are at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-TP2U1804AMD64-16366/test Topology Tests failed for Topo tests part 2 on Ubuntu 18.04 amd64:
see full log at https://ci1.netdef.org/browse/FRR-FRRPULLREQ-16366/artifact/TP2U1804AMD64/ErrorLog/log_topotests.txt Successful on other platforms/tests
Warnings Generated during build:Debian 10 amd64 build: Successful with additional warningsDebian Package lintian failed for Debian 10 amd64 build:
|
Outdated results 💚Basic BGPD CI results: SUCCESS, 0 tests failed
For details, please contact louberger |
Continuous Integration Result: FAILEDContinuous Integration Result: FAILEDSee below for issues. This is a comment from an automated CI system. Get source / Pull Request: SuccessfulBuilding Stage: SuccessfulBasic Tests: FailedTopo tests part 3 on Ubuntu 18.04 arm8: Failed (click for details)Topo tests part 3 on Ubuntu 18.04 arm8: No useful log foundSuccessful on other platforms/tests
Warnings Generated during build:Debian 10 amd64 build: Successful with additional warningsDebian Package lintian failed for Debian 10 amd64 build:
|
can we rebase and force push from latest master into this branch? this will pick up the gr test fixes. |
I'll get this in after that |
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
Signed-off-by: ckishimo <carles.kishimoto@gmail.com>
Continuous Integration Result: SUCCESSFULCongratulations, this patch passed basic tests Tested-by: NetDEF / OpenSourceRouting.org CI System CI System Testrun URL: https://ci1.netdef.org/browse/FRR-FRRPULLREQ-16459/ This is a comment from an automated CI system. Warnings Generated during build:Debian 10 amd64 build: Successful with additional warningsDebian Package lintian failed for Debian 10 amd64 build:
|
💚 Basic BGPD CI results: SUCCESS, 0 tests failedResults table
For details, please contact louberger |
In OSPF tests there are a couple of local functions for the redistribution of
statics
andconnected
routes. This PR fixes the key"del_action"
that should be called"delete"
At the end I ended up merging both functions (
red_static
andred_connected
) into a single function calledredistribute
. Also 3 different commits were performed to ease the reviewAlso this PR fixes a few typos in the output when running OSPF tests:
Signed-off-by: ckishimo carles.kishimoto@gmail.com