-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
go/analysis/analysistest: stricter errors and GOWORK setting
This change causes analysistest to report complete failure to load one or more of the packages named by the load patterns. (This is indicated by a missing Package.Name.) Previously, these errors were silently ignored, meaning that tests were providing less coverage than they seemed. In particular, the stdversion test was unable to load the specified modules because there was no GOWORK file to locate them. (Worse: the user's GOWORK environment was affecting the test.) So, we now allow tests to specify a go.work file in the root of the test tree. If present, we honor it, and, crucially, if absent, we set GOWORK=off. Also, two other tests in gopls/internal/analysis were silently doing nothing (!). Change-Id: I4ee7ae2a636497a64f1e43eb05a4a414ceaa5f4a Reviewed-on: https://go-review.googlesource.com/c/tools/+/582595 Auto-Submit: Alan Donovan <adonovan@google.com> Reviewed-by: Tim King <taking@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
- Loading branch information
Showing
6 changed files
with
28 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters