Skip to content

Fix progress eval test randomly failing#2590

Merged
pepeiborra merged 2 commits into
haskell:masterfrom
eddiemundo:fix-progress-test-random-fail
Jan 15, 2022
Merged

Fix progress eval test randomly failing#2590
pepeiborra merged 2 commits into
haskell:masterfrom
eddiemundo:fix-progress-test-random-fail

Conversation

@eddiemundo

@eddiemundo eddiemundo commented Jan 15, 2022

Copy link
Copy Markdown
Collaborator

Fixes #2578.

Took way too long to find for how simple it was. The issue was that getCodeLenses was occasionally eating progress create messages, which caused any further messages with the same progress tokens to fail.

The implemented fix is to expect progress messages up to the point of the code lens response, do whatever we need the code lens response for, then pass the currently active progress tokens to the final expect progress messages function finishing up the expectations.

The other progress tests should be fine since they don't eat messages.

@pepeiborra pepeiborra left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome! The effort invested in fixing these subtle flaky tests often goes unnoticed so please accept my unlimited gratitude.

Comment thread test/functional/Progress.hs Outdated
Comment thread test/functional/Progress.hs Outdated
@pepeiborra
pepeiborra merged commit acff2bd into haskell:master Jan 15, 2022
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.

Flaky test suite: progress reporting (func-test)

2 participants