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

Fix test_monit #3708

Merged
merged 1 commit into from
Jun 29, 2021
Merged

Fix test_monit #3708

merged 1 commit into from
Jun 29, 2021

Conversation

bingwang-ms
Copy link
Collaborator

Description of PR

Summary:
test_monit began to fail with following error

exit_code = monit_status_result["rc"]
>       pytest_assert(exit_code == 0, "Monit is either not running or not configured correctly")
E       Failed: Monit is either not running or not configured correctly

The root cause is test cases running before this one will restart monit status, and it will take up to 300 seconds for monit to be reloaded.
This PR addressed the issue by adding a wait_until logic.

Signed-off-by: bingwang [email protected]

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?

This PR is to fix test_monit.

How did you do it?

This PR addressed the issue by adding a wait_until logic.

How did you verify/test it?

Verified by running test_monit after test_memory_checker, which will restart monit service.

Any platform specific information?

No.

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

No.

Documentation

Signed-off-by: bingwang <[email protected]>
@bingwang-ms bingwang-ms requested a review from a team as a code owner June 28, 2021 02:20
@bingwang-ms bingwang-ms requested a review from yozhao101 June 28, 2021 02:20
@yozhao101
Copy link
Contributor

@bingwang-ms Thanks so much for helping me fix this bug issue. I appreciate it.

@bingwang-ms bingwang-ms merged commit d9aafac into sonic-net:master Jun 29, 2021
vmittal-msft pushed a commit to vmittal-msft/sonic-mgmt that referenced this pull request Sep 28, 2021
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