]> Cypherpunks repositories - gostls13.git/commit
crypto/tls: replay test recordings without network
authorFilippo Valsorda <filippo@golang.org>
Sun, 23 Jun 2024 12:10:14 +0000 (14:10 +0200)
committerGopher Robot <gobot@golang.org>
Mon, 24 Jun 2024 16:40:26 +0000 (16:40 +0000)
commitcf54a3d11469e3e9bd531ee2cdeaf613467923f1
treecad9a928714b709b09cd02723fcd00a6a4c967e2
parentb98803e8e5e4e3077207d5c473f1938dfd9dcff2
crypto/tls: replay test recordings without network

There is no reason to go across a pipe when replaying a conn recording.
This avoids the complexity of using localPipe and goroutines, and makes
handshake benchmarks more accurate, as we don't measure network
overhead.

Also note how it removes the need for -fast: operating locally we know
when the flow is over and can error out immediately, without waiting for
a read from the feeder on the other side of the pipe to timeout.

Avoids some noise in #67979, but doesn't fix the two root causes:
localPipe flakes and testing.B races.

Updates #67979

Change-Id: I153d3fa5a24847f3947823e8c3a7bc639f89bc1d
Reviewed-on: https://go-review.googlesource.com/c/go/+/594255
Auto-Submit: Filippo Valsorda <filippo@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Roland Shoemaker <roland@golang.org>
Reviewed-by: Joedian Reid <joedian@google.com>
src/crypto/tls/handshake_client_test.go
src/crypto/tls/handshake_server_test.go
src/crypto/tls/handshake_test.go