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

[action] [PR:14788] Retry test_psu.py::TestPsuApi::test_power if power not within tolerance #15587

Open
wants to merge 1 commit into
base: 202311
Choose a base branch
from

Commits on Nov 15, 2024

  1. Retry test_psu.py::TestPsuApi::test_power if power not within toleran…

    …ce (sonic-net#14788)
    
    * Retry test_power calculated power above 10%
    
    If the test fails on `abs(power - (voltage*current)) < power*0.1` then retry the test. Test is repeated for a maximum of three times until it passes, else it is failed.
    This change is introduced to account for the stringent tolerance level of 10% and the errors that might be caused due to time differences reading each of the parameters.
    
    * Retry test_power.py::TestPsuApi::test_power if power above tolerance
    
    If the test fails on `abs(power - (voltage*current)) < power*0.1` then retry the test. The test is repeated for a maximum of three times until it passes.
    This change is introduced to account for the stringent tolerance level of 10% and the errors that might be caused due to time differences in reading each of the parameters.
    
    * Add check to detect occurrence of a failure before power calculation
    
    * Resolve pre-commit check issue
    
    * Refactor test_power function to improve readability
    
    * Use wait_until function for retry
    smagarwal-arista authored and mssonicbld committed Nov 15, 2024
    Configuration menu
    Copy the full SHA
    f7d1541 View commit details
    Browse the repository at this point in the history