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] De-flake Timer tests #12795

Merged
merged 2 commits into from
Aug 24, 2020

Conversation

antoniovicente
Copy link
Contributor

Commit Message:
De-flake Timer tests by moving timer registrations inside the event loop in order to take advantage of cached monotonic time during timer registration.
When the event loop is not running, real monotonic time keeps moving forward which can result in timers ending up with registration times that are the opposite of what's intended by the test and thus result in spurious test failures.
Additional Description:
Risk Level: n/a
Testing: No flakes after 30k runs
Docs Changes: n/a
Release Notes: n/a
Fixes #12532

…oop in order to take advantage of cached monotonic time during timer registration.

When the event loop is not running, real monotonic time keeps moving forward which can result in timers ending up with registration times that are the opposite of what's intended by the test and thus result in spurious test failures.

Signed-off-by: Antonio Vicente <avd@google.com>
jmarantz
jmarantz previously approved these changes Aug 24, 2020
@jmarantz
Copy link
Contributor

clang-tidy needs fix

Signed-off-by: Antonio Vicente <avd@google.com>
@antoniovicente
Copy link
Contributor Author

clang-tidy needs fix

Should be fixed now.

@mattklein123
Copy link
Member

Existing flake will merge.

@mattklein123 mattklein123 merged commit ae0229b into envoyproxy:master Aug 24, 2020
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.

TSAN DelayActivation/TimerImplTest.ChangeTimerForwardsToNonZeroBeforeRun/0 flake
3 participants