Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
internal/lsp: attempt to make TestDebouncer more robust
CL 309276 added logic to retry TestDebouncer if its execution was determined to be invalid. Unfortunately it also reduced the delay period, which increases the likelihood of a flake on any individual execution. This appears to have more than offset any robustness resulting from the retries. This CL does a few things to try to improve the test: - Remove t.Parallel: we want goroutines to be scheduled quickly. - Increase the debouncing delay. - Improve the logic for determining if a test was invalid. - Guard the valid variable with a mutex, since this was actually racy. For golang/go#45085 Change-Id: Ib96c9a215d58606d3341f90774706945fcf9b06c Reviewed-on: https://go-review.googlesource.com/c/tools/+/333349 Trust: Robert Findley <rfindley@google.com> gopls-CI: kokoro <noreply+kokoro@google.com> Run-TryBot: Robert Findley <rfindley@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Rebecca Stambler <rstambler@golang.org>
- Loading branch information