1
0
mirror of https://github.com/golang/go synced 2024-11-15 00:40:31 -07:00

crypto/tls: fix test caching for bogo

Use a stat to tell the test caching infrastructure that we care about
the bogo config file.

Change-Id: Iae2336bfc45cd6a9e73cb83a3b68ade8b4f23927
Reviewed-on: https://go-review.googlesource.com/c/go/+/589155
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Filippo Valsorda <filippo@golang.org>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
Auto-Submit: Roland Shoemaker <roland@golang.org>
This commit is contained in:
Roland Shoemaker 2024-05-29 10:38:15 -07:00 committed by Gopher Robot
parent b5a8617823
commit b91f054a64

View File

@ -301,6 +301,14 @@ func TestBogoSuite(t *testing.T) {
t.Skip("#66913: windows network connections are flakey on builders")
}
// In order to make Go test caching work as expected, we stat the
// bogo_config.json file, so that the Go testing hooks know that it is
// important for this test and will invalidate a cached test result if the
// file changes.
if _, err := os.Stat("bogo_config.json"); err != nil {
t.Fatal(err)
}
var bogoDir string
if *bogoLocalDir != "" {
bogoDir = *bogoLocalDir