]> Cypherpunks repositories - gostls13.git/commit
cmd/go: make TestScript/gotoolchain more realistic
authorBryan C. Mills <bcmills@google.com>
Wed, 19 Apr 2023 19:59:19 +0000 (15:59 -0400)
committerGopher Robot <gobot@golang.org>
Thu, 18 May 2023 19:37:07 +0000 (19:37 +0000)
commit308ca75edbe152d515d8aeab439c995bfeed5534
tree17f31a6d11a250a6f980abed527e43a5ef376c05
parentebfd80ba6f231f80484d5fedca5b60e1f166644e
cmd/go: make TestScript/gotoolchain more realistic

- Build the fake go1.999testpath binary from Go source instead of
  special-casing a fake command on Windows.

- Skip the part of the test that uses shell scripts served from the
  test GOPROXY if /bin/sh is not present.

This makes the test more expensive, but also more realistic: notably,
it does not require test hooks to determine whether to run a real or
fake binary.

Change-Id: If14fec52186631d7833eba653c91ec5198dede58
Reviewed-on: https://go-review.googlesource.com/c/go/+/486400
Run-TryBot: Bryan Mills <bcmills@google.com>
Auto-Submit: Bryan Mills <bcmills@google.com>
Reviewed-by: Michael Matloob <matloob@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
src/cmd/go/gotoolchain.go
src/cmd/go/testdata/script/gotoolchain.txt