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

[Backport 2.x] Fix flaky DecommissionControllerTests.testTimesOut (#4683) (#4688) #5206

Merged
merged 1 commit into from
Nov 10, 2022

Commits on Nov 10, 2022

  1. Fix flaky DecommissionControllerTests.testTimesOut (opensearch-projec…

    …t#4683) (opensearch-project#4688)
    
    This test fails pretty reliably if I run it on repeat. I believe the
    problem is that the test assumes the function will take longer than 2ms,
    which is likely not a valid assumption in all cases. Fortunately, I can
    pass in a zero duration which is guaranteed to timeout even if the
    system clock does not advance at all.
    
    Also moved the assertions out of the callback into the main test method,
    otherwise the assertion error messages would get buried and the test
    report would just show a timeout error.
    
    Signed-off-by: Andrew Ross <andrross@amazon.com>
    andrross committed Nov 10, 2022
    Configuration menu
    Copy the full SHA
    cdb1183 View commit details
    Browse the repository at this point in the history