Skip to content
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

[port2alias]: Fix to get right number of return values #1906

Merged
merged 10 commits into from
Dec 6, 2021

Conversation

SuvarnaMeenakshi
Copy link
Contributor

from get_port_config. Modified to get ports from all
namespaces and added unit test cases.

Signed-off-by: SuvarnaMeenakshi sumeenak@microsoft.com

What I did

get_port_config was modified to return different set number of arguments in PR: sonic-net/sonic-buildimage#4222. Changes in this PR is:

  1. To address the different set of return values
  2. To get the ports from all namespaces
  3. To add unit-test

How I did it

Modify port2alias to read ports from all namespaces and also add unit-test

How to verify it

Test on single and multi-asic platforms.
unit-test passed.

Previous command output (if the output of a command-line utility has changed)

New command output (if the output of a command-line utility has changed)

from get_port_config. Modified to get ports from all
namespaces and added unit test cases.

Signed-off-by: SuvarnaMeenakshi <sumeenak@microsoft.com>
Signed-off-by: SuvarnaMeenakshi <sumeenak@microsoft.com>
Signed-off-by: Suvarna Meenakshi <sumeenak@microsoft.com>
Signed-off-by: Suvarna Meenakshi <sumeenak@microsoft.com>
Signed-off-by: Suvarna Meenakshi <sumeenak@microsoft.com>
Signed-off-by: Suvarna Meenakshi <sumeenak@microsoft.com>
Signed-off-by: Suvarna Meenakshi <sumeenak@microsoft.com>
@SuvarnaMeenakshi
Copy link
Contributor Author

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@SuvarnaMeenakshi SuvarnaMeenakshi merged commit 3714f63 into sonic-net:master Dec 6, 2021
abdosi pushed a commit that referenced this pull request Dec 8, 2021
What I did
get_port_config was modified to return different set number of arguments in PR: sonic-net/sonic-buildimage#4222. Changes in this PR is:

To address the different set of return values
To get the ports from all namespaces
To add unit-test
How I did it
Modify port2alias to read ports from all namespaces and also add unit-test

How to verify it
Test on single and multi-asic platforms.
unit-test passed.
@qiluo-msft
Copy link
Contributor

This commit could not be cleanly cherry-picked to 202012. Please submit another PR.

SuvarnaMeenakshi added a commit to SuvarnaMeenakshi/sonic-utilities that referenced this pull request May 27, 2022
What I did
get_port_config was modified to return different set number of arguments in PR: sonic-net/sonic-buildimage#4222. Changes in this PR is:

To address the different set of return values
To get the ports from all namespaces
To add unit-test
How I did it
Modify port2alias to read ports from all namespaces and also add unit-test

How to verify it
Test on single and multi-asic platforms.
unit-test passed.

(cherry picked from commit 3714f63)
Signed-off-by: Suvarna Meenakshi <sumeenak@microsoft.com>
SuvarnaMeenakshi added a commit that referenced this pull request Jun 13, 2022
What I did
Cherry-pick of #1906 to 202012 branch
Fix conflict also few changes done to cherry-pick:

get_port_config function takes asic id as argument in 2019/202012 branches
Keep load_source of port2alias as module, as is used in unit-test in 202012 branch
get_port_config was modified to return different set number of arguments in PR: sonic-net/sonic-buildimage#4222. Changes in this PR is:

To address the different set of return values
To get the ports from all namespaces
To add unit-test
Additional change done over the cherry-pick:
added setup_class method in test case to load single asic mock db, this was done in pfcwd_test teardown method in 201911 and master branches. It is not done in 202012 branch, hence added setup_class method.

How I did it
Modify port2alias to read ports from all namespaces and also add unit-test

How to verify it
Verified on single and multi-asic DUTs with 202012 image.
@liuh-80
Copy link
Contributor

liuh-80 commented Feb 2, 2023

202012 branch PR merged: #2188

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants