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 flaky render test by dropping old spinners #463

Closed

Conversation

chris-laplante
Copy link
Collaborator

@chris-laplante chris-laplante commented Aug 10, 2022

Before this change, the ticker_drop render test was occasionally
flaky.

Reproduce it by running this command:

while cargo test --all-features ticker_drop; do :; done

It will eventually fail with something like this:

running 1 test
test ticker_drop ... FAILED

failures:

---- ticker_drop stdout ----
thread 'ticker_drop' panicked at 'assertion failed: `(left == right)`
  left: `"⠁ doing stuff 0\n  doing stuff 1\n  doing stuff 2\n  doing stuff 3\n  doing stuff 4"`,
 right: `"  doing stuff 0\n  doing stuff 1\n  doing stuff 2\n  doing stuff 3\n  doing stuff 4"`', tests/render.rs:347:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

Somehow the spinner is not correctly getting finished. Clearly there is
a subtle race condition somewhere but I haven't been able to track it
down.

Before this change, the ticker_drop render test was occasionally
flaky.

Reproduce it by running this command:

    while cargo test --all-features ticker_drop; do :; done

It will eventually fail with something like this:

===========
running 1 test
test ticker_drop ... FAILED

failures:

---- ticker_drop stdout ----
thread 'ticker_drop' panicked at 'assertion failed: `(left == right)`
  left: `"⠁ doing stuff 0\n  doing stuff 1\n  doing stuff 2\n  doing stuff 3\n  doing stuff 4"`,
 right: `"  doing stuff 0\n  doing stuff 1\n  doing stuff 2\n  doing stuff 3\n  doing stuff 4"`', tests/render.rs:347:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
===========

Somehow the spinner is not correctly getting finished. Clearly there is
a subtle race condition somewhere but I haven't been able to track it
down.
@chris-laplante
Copy link
Collaborator Author

@djc I think this fixes what you encountered here: #458 (comment)

@djc
Copy link
Collaborator

djc commented Aug 11, 2022

If you reproduced this I think we should probably not paper over this in the test? At the very least we should file an issue about it.

@chris-laplante
Copy link
Collaborator Author

chris-laplante commented Aug 11, 2022

If you reproduced this I think we should probably not paper over this in the test? At the very least we should file an issue about it.

Sure, I'll file an issue. I'll close this PR then.

@chris-laplante chris-laplante deleted the cpl/flaky-ticker-test branch August 12, 2022 21:26
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.

None yet

2 participants