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 slow test telemetry.all_peers_use_single_request_cache #3677

Conversation

dsiganos
Copy link
Contributor

And rename it to telemetry.cache_read_and_timeout.

The test was broken because it did a sleep for 7 seconds.
In unit tests, any waiting should be done with ASSERT_TIMELY, or something
similar, so that the system's poll() function is called regularly.

In this case, the poll() function wasn't called for 7 seconds, which
caused things to timeout and comms to be disrupted. The solution was to
replace the sleep with an ASSERT_TIMELY.

And rename it to telemetry.cache_read_and_timeout.

The test was broken because it did a sleep for 7 seconds.
In unit tests, any waiting should be done with ASSERT_TIMELY, or something
similar, so that the system's poll() function is called regularly.

In this case, the poll() function wasn't called for 7 seconds, which
caused things to timeout and comms to be disrupted. The solution was to
replace the sleep with an ASSERT_TIMELY.
@dsiganos dsiganos added the unit test Related to a new, changed or fixed unit test label Jan 18, 2022
@dsiganos dsiganos merged commit 584bfbf into nanocurrency:develop Jan 19, 2022
@dsiganos dsiganos deleted the fix_telemetry_all_peers_use_single_request_cache branch January 19, 2022 10:50
@zhyatt zhyatt added this to the V24.0 milestone Jan 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
unit test Related to a new, changed or fixed unit test
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants