These tests probably shouldn't run on GOARCH=wasm. They fail due to "not implemented" errors, e.g.:

=== RUN   TestFreeRefs/file2.go
    freesymbols_test.go:107: file2.go:1:19: could not import fmt (can't find import: "fmt": pipe: Not implemented on wasip1)
    freesymbols_test.go:107: file2.go:1:43: declared and not used: x
    freesymbols_test.go:128: (-want +got)
          []string{
        -   "file pkgname fmt.Stringer",
        +   "file pkgname fmt",
          }
--- FAIL: TestFreeRefs/file2.go (0.00s)
=== RUN   TestDriverConformance/builtin
    driver.go:44: Executable not implemented for wasip1
--- FAIL: TestDriverConformance/builtin (0.00s)

See https://ci.chromium.org/b/8744215260434519153/test-results for example.

CL 588755 added a skip on GOOS=js to TestFreeRefs (but not for other GOARCH=wasm ports like GOOS=wasip1).

CC @golang/wasm.

Comment From: gopherbot

Change https://go.dev/cl/594895 mentions this issue: gopls: skip failing tests on wasm/wasip1