fix flaky TestConnectionUnpackFailureDropped (#5382)

* Initial plan

* Fix flaky TestConnectionUnpackFailureDropped by adding synctest.Wait

Co-authored-by: marten-seemann <1478487+marten-seemann@users.noreply.github.com>

* formatting

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: marten-seemann <1478487+marten-seemann@users.noreply.github.com>
Co-authored-by: Marten Seemann <martenseemann@gmail.com>
This commit is contained in:
Copilot
2025-10-24 17:47:19 +02:00
committed by GitHub
parent f2b845a2f5
commit 9a7936d2ca

View File

@@ -862,6 +862,9 @@ func testConnectionUnpackFailureDropped(t *testing.T, unpackErr error, packetDro
// test teardown
tc.connRunner.EXPECT().Remove(gomock.Any()).AnyTimes()
tc.conn.destroy(nil)
synctest.Wait()
select {
case <-errChan:
default: