-
Notifications
You must be signed in to change notification settings - Fork 740
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
[platform] Implement platform phase 1 cases #915
Conversation
Signed-off-by: Xin Wang <xinw@mellanox.com>
@jleveque Could you please help review this PR? |
Changes: * Add mellanox_psu_controller.py which has Mellanox implementation of PSU controller. * Increase the delay between reset SFP and checking SFP presence for SFP to be fully recovered. * Improve the checking of PSU status. * Correct spelling errors. Signed-off-by: Xin Wang <xinw@mellanox.com>
@jleveque Any more comments or concerns? |
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.
Looks good to me
tests/platform/test_platform_info.py
Outdated
hostname = testbed['dut'] | ||
ans_host = ansible_host(ansible_adhoc, hostname) | ||
|
||
logging.info("Check output of 'show platform summary'") |
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.
In general I suggest that commands name as well as expected error/OK message will be defined once (as a constant) and will be used by both log info as well as he command / message to use.
it is simpler in term changes might be introduced later on and code change will be done only once
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.
Sure, updated in the new commit.
return res | ||
|
||
|
||
def test_check_sfp_status_and_configure_sfp(localhost, ansible_adhoc, testbed): |
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.
If i am not mistaken we also have low power mode option under sfputil. Should we add it as well?
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.
Sure. Added SFP low power mode testing in the new commit.
* Replace inline command strings with predefined variables * Add test case for testing SFP low power mode Signed-off-by: Xin Wang <xinw@mellanox.com>
@lguohan @liat-grozovik Any more comments? |
The order of information output by command "show platform syseeprom" is not guranteed. This commit improve the method of comparing the content output by syseeprom plugin and the show command to avoid the failure caused by inconsistent output order. Signed-off-by: Xin Wang <xinw@mellanox.com>
Added a new commit fixing an issue of comparing syseeprom output from "show platform syseeprom" and platform plugin. |
Description of PR
Summary:
Fixes # (issue)
Implement the SONiC platform phase 1 test cases using the pytest-ansible framework.
The SONiC platform test cases are documented here:
https://github.com/Azure/SONiC/blob/master/doc/pmon/sonic_platform_test_plan.md
Test cases implemented in phase 1:
Please note that only the scripts for common test cases were included in this PR.
Type of change
Approach
How did you do it?
Implement the SONiC platform phase 1 test cases using the pytest-ansible framework and follow the design of PR #802
How did you verify/test it?
Tested on the mellanox platform
Any platform specific information?
This PR does not include platform specific test cases.
Supported testbed topology if it's a new test case?
All current test topologies are supported:
[t0, t0-16, t0-56, t0-64, t0-64-32, t0-116, t1, t1-lag, t1-64-lag, ptf32, ptf64]
Documentation
The SONiC platform test plan:
https://github.com/Azure/SONiC/blob/master/doc/pmon/sonic_platform_test_plan.md