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

Refractored Breakout Mode CLI subcommand with speed fix #7

Merged
merged 1 commit into from
Dec 13, 2019

Conversation

samaity
Copy link
Collaborator

@samaity samaity commented Dec 13, 2019

Signed-off-by: Sangita Maity sangitamaity0211@gmail.com

- What I did
Refactored the code. Removed a function that is not needed anymore. Speed is now properly populated via portconfig.py

This PR is dependent on portconfig.py file in sonic-buildimage

- How I did it
using portconfig.py in sonic build image.

  • How to verify it
    Verified using VS test case mentioned here

samaity@server09:~/REPO_FACTORY/GIT_REPO/DPB/sonic-buildimage/platform/vs/tests/breakout$ sudo pytest -s -v --dvsname=vs-sang test_breakout_cli.py
========================================================================================= test session starts =========================================================================================
platform linux2 -- Python 2.7.15+, pytest-3.3.0, py-1.8.0, pluggy-0.6.0 -- /usr/bin/python
cachedir: .cache
rootdir: /home/samaity/REPO_FACTORY/GIT_REPO/DPB/sonic-buildimage/platform/vs/tests/breakout, inifile:
collected 2 items

test_breakout_cli.py::TestBreakoutCli::test_InitialBreakoutMode remove extra link dummy
PASSED                                                                                      [ 50%]
test_breakout_cli.py::TestBreakoutCli::test_mode_1X100G **** Breakout Cli test Starts ****
**** 1X100G --> 2x50G passed ****
**** 2x50G --> 1x100G[40G] passed ****
**** 1X100G --> 4x25G[10G] passed ****
**** 4x25G[10G] --> 1x100G[40G] passed ****
**** 1x100G[40G] --> 2x25G(2)+1x50G(2) passed ****
**** 2x25G(2)+1x50G(2) --> 1x100G[40G] passed ****
**** 1x100G[40G] --> 1x50G(2)+2x25G(2)  passed ****
**** 1x50G(2)+2x25G(2) --> 1x100G[40G] passed ****
**** 1x100G[40G] --> 2x50G  passed ****
**** 2x50G --> 2x25G(2)+1x50G(2)  passed ****
**** 1x50G(2)+2x25G(2) --> 2x25G(2)+1x50G(2)  passed ****
**** 2x25G(2)+1x50G(2)  --> 1x100G[40G]  passed ****
PASSED                                                                                              [100%]

Signed-off-by: Sangita Maity <sangitamaity0211@gmail.com>
@zhenggen-xu zhenggen-xu merged commit 9dbc71d into zhenggen-xu:sonic-cfg-mgmt Dec 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants