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

[test_reboot] Check time passed before checking warmboot finalizer state #4706

Merged
merged 1 commit into from
Nov 17, 2021

Conversation

vaibhavhd
Copy link
Contributor

Description of PR

Summary: Fix false negatives in test_reboot.py::test_warm_reboot when finalizer state is checked before checking time passed since warm-reboot.
Fixes # (issue)

Type of change

  • Bug fix
  • Testbed and Framework(new/improvement)
  • Test case(new/improvement)

Back port request

  • 201911

Approach

What is the motivation for this PR?

Fix false negatives in test_reboot.py::test_warm_reboot.

If more than 90s have passed since issue of warm-reboot, the test should fail, even if warmboot FINALIZER state has reached activating.

Without this change, if in the first attempt to check if FINALIZER state reaches activating passes, the time passed since reboot is not checked.

How did you do it?

The sequence of checks is now reverted - first check the time elapsed since issue of warm-reboot, then check the finalizer state. If elapsed time is greater than the wait (default 90s), and finalizer still reaches activating state, then fail the test.

How did you verify/test it?

With the fix, the false negative scenario is not seen. The test fails if elapsed time is greater than the wait period.

Any platform specific information?

Supported testbed topology if it's a new test case?

Documentation

@vaibhavhd vaibhavhd requested a review from a team as a code owner November 16, 2021 11:19
@vaibhavhd vaibhavhd merged commit c2449c3 into sonic-net:master Nov 17, 2021
@vaibhavhd vaibhavhd deleted the warmboot-finalizer-timing branch November 17, 2021 01:34
AntonHryshchuk pushed a commit to AntonHryshchuk/sonic-mgmt that referenced this pull request Jan 4, 2022
…ate (sonic-net#4706)

Fix false negatives in test_reboot.py::test_warm_reboot.
If more than 90s have passed since issue of warm-reboot, the test should fail, even if warmboot FINALIZER state has reached activating.
Without this change, if in the first attempt to check if FINALIZER state reaches activating passes, the time passed since reboot is not checked.
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.

3 participants