Generalizing GCU test suite to verify both ip types (IPV4, IPV6) for BGP Neighbors#13650
Conversation
Currently, under generic config update there is a test suite verifying only IPV6 BGP Neighbors' changes. This PR extends the existing test suite and adds support for verifying IPV4 BGP NEighbors also. This is achieved by generalizing the test code with adding dynamic variable for neighbor ip type and with test mark parameters. Also, renamed the test suite to a generic name. Signed-off-by: karavasi <[email protected]>
|
The pre-commit check detected issues in the files touched by this pull request. Detailed pre-commit check results: To run the pre-commit checks locally, you can follow below steps:
|
…lure Signed-off-by: karavasi <[email protected]>
|
Hello @judyjoseph @arlakshm , Could you please help on reviewing this? |
|
LGTM, @okaravasi could you resolve the conflicts. Also do add a snapshot of the test run for ipv4 and ipv6 under the section "How did you verify/test it?" |
Done: Updated the branch and included screenshot from kvm-t0 run in the description. |
|
@okaravasi Arvind had a comment earlier -- that we need to add support for multi-asic as well. Do you plan to do it in this PR ? |
@judyjoseph Support to multi-asic will be handled by different PRs.
|
…BGP Neighbors (sonic-net#13650) * Motivation for this PR: Currently, under generic config update there is a test suite verifying only IPV6 BGP Neighbors' changes. This PR extends the existing test suite and adds support for verifying IPV4 BGP NEighbors also. This is achieved by generalizing the test code with adding dynamic variable for neighbor ip type and with test mark parameters. Also, renamed the test suite to a generic name. Signed-off-by: karavasi <[email protected]> * adding extra line before test case definition due to flake8 check failure Signed-off-by: karavasi <[email protected]> --------- Signed-off-by: karavasi <[email protected]>
Script tests/generic_config_updater/test_ipv6.py was renamed to tests/generic_config_updater/test_ip_bgp.py in PR sonic-net#13650 Need to update file name in pr_test_scripts.yaml to ensure that renamed script is covered by PR testing. Signed-off-by: Xin Wang <[email protected]>
Script tests/generic_config_updater/test_ipv6.py was renamed to tests/generic_config_updater/test_ip_bgp.py in PR #13650 Need to update file name in pr_test_scripts.yaml to ensure that renamed script is covered by PR testing. Signed-off-by: Xin Wang <[email protected]>
What is the motivation for this PR? Script tests/generic_config_updater/test_ipv6.py was renamed to tests/generic_config_updater/test_ip_bgp.py in PR #13650 Need to update file name in pr_test_scripts.yaml to ensure that renamed script is covered by PR testing. How did you do it? Rename script name from generic_config_updater/test_ipv6.py to generic_config_updater/test_ip_bgp.py
…BGP Neighbors (sonic-net#13650) * Motivation for this PR: Currently, under generic config update there is a test suite verifying only IPV6 BGP Neighbors' changes. This PR extends the existing test suite and adds support for verifying IPV4 BGP NEighbors also. This is achieved by generalizing the test code with adding dynamic variable for neighbor ip type and with test mark parameters. Also, renamed the test suite to a generic name. Signed-off-by: karavasi <[email protected]> * adding extra line before test case definition due to flake8 check failure Signed-off-by: karavasi <[email protected]> --------- Signed-off-by: karavasi <[email protected]>
Script tests/generic_config_updater/test_ipv6.py was renamed to tests/generic_config_updater/test_ip_bgp.py in PR sonic-net#13650 Need to update file name in pr_test_scripts.yaml to ensure that renamed script is covered by PR testing. Signed-off-by: Xin Wang <[email protected]>
What is the motivation for this PR? Script tests/generic_config_updater/test_ipv6.py was renamed to tests/generic_config_updater/test_ip_bgp.py in PR sonic-net#13650 Need to update file name in pr_test_scripts.yaml to ensure that renamed script is covered by PR testing. How did you do it? Rename script name from generic_config_updater/test_ipv6.py to generic_config_updater/test_ip_bgp.py
|
@wen587 Can you please check if this change is required for 202405? |
Hi @bingwang-ms , this is an improvement from ipv6 only test to ipv4+ipv6 test. It is good to have in 202405 but not bug fix related. |
test_ipv6.py was renamed to test_ip_bgp.py in sonic-net#13650 but the reference in kvmtest.sh was not updated, causing 'file not found' errors during kvmtest t0 runs. Co-Authored-By: Arthur Poon <[email protected]>
Add sed patch to fix the stale test_ipv6.py reference in kvmtest.sh that was renamed to test_ip_bgp.py in sonic-net/sonic-mgmt#13650. This was causing 'file or directory not found' errors during kvmtest. Co-Authored-By: Arthur Poon <[email protected]>
Currently, under generic config update there is a test suite verifying only IPV6 BGP Neighbors' changes. This PR extends the existing test suite and adds support for verifying IPV4 BGP NEighbors also. This is achieved by generalizing the test code with adding dynamic variable for neighbor ip type and with test mark parameters. Also, renamed the test suite to a generic name.
Description of PR
Summary:
This is an improvement on existing test suite generic_config_updater/test_ipv6.py
Currently, under generic config update there is a test suite verifying only IPV6 BGP Neighbors' changes. This PR extends the existing test suite and adds support for verifying IPV4 BGP NEighbors also. This is achieved by generalizing the test code with adding dynamic variable for neighbor ip type and with test mark parameters. Also, renamed the test suite to a generic name.
Type of change
Back port request
Approach
What is the motivation for this PR?
Currently, there are no test cases for IPv4 BGP Neighbors in the verification of generic config updates functionality. This PR extends the existing test suite, which verifies IPv6 BGP Peers, to add support for IPv4 BGP Neighbors verification.
How did you do it?
Added argument for ip_version in test functions to dynamically verify the relevant peer IP type.
Added test mark parameters to run the same test case for both IP types.
Renamed the test suite to a generic name that reflects new test cases content.
How did you verify/test it?
Ran the newly created test suite and verified that the test cases pass for both IP types.
Any platform specific information?
N/A
Supported testbed topology if it's a new test case?
N/A
Documentation