-
Notifications
You must be signed in to change notification settings - Fork 763
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: remove dependency on source code in GOPATH #6
Labels
chore/testing
issues related to bugs in test, CI setup
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
Comments
gopherbot
pushed a commit
that referenced
this issue
Mar 17, 2020
If the env var GOPATH is not set when the test runs, now it runs `go env GOPATH` to retrieve the default value the underlying go commands will use. I wished I could make this command run asynchronously, but I am not familiar with the test framework and failed to make it working with async functions. So, like many other file operations used in the test setup phase, I am using execFileSync. Update #6 Change-Id: Id075827ab8ebd955f7a86460aaa7ea4e0e7cd183 GitHub-Last-Rev: 6222158 GitHub-Pull-Request: #8 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/223177 Reviewed-by: Andrew Bonventre <[email protected]>
hyangah
added a commit
to hyangah/vscode-go-old
that referenced
this issue
Mar 20, 2020
If the env var GOPATH is not set when the test runs, now it runs `go env GOPATH` to retrieve the default value the underlying go commands will use. I wished I could make this command run asynchronously, but I am not familiar with the test framework and failed to make it working with async functions. So, like many other file operations used in the test setup phase, I am using execFileSync. Update golang/vscode-go#6 Change-Id: Id075827ab8ebd955f7a86460aaa7ea4e0e7cd183 GitHub-Last-Rev: 6222158 GitHub-Pull-Request: golang/vscode-go#8 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/223177 Reviewed-by: Andrew Bonventre <[email protected]>
hyangah
added a commit
to hyangah/vscode-go-old
that referenced
this issue
Mar 28, 2020
If the env var GOPATH is not set when the test runs, now it runs `go env GOPATH` to retrieve the default value the underlying go commands will use. I wished I could make this command run asynchronously, but I am not familiar with the test framework and failed to make it working with async functions. So, like many other file operations used in the test setup phase, I am using execFileSync. Update golang/vscode-go#6 Change-Id: Id075827ab8ebd955f7a86460aaa7ea4e0e7cd183 GitHub-Last-Rev: 6222158 GitHub-Pull-Request: golang/vscode-go#8 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/223177 Reviewed-by: Andrew Bonventre <[email protected]>
ramya-rao-a
pushed a commit
to microsoft/vscode-go
that referenced
this issue
Mar 28, 2020
* test/integration: use default GOPATH when the env var is not set If the env var GOPATH is not set when the test runs, now it runs `go env GOPATH` to retrieve the default value the underlying go commands will use. I wished I could make this command run asynchronously, but I am not familiar with the test framework and failed to make it working with async functions. So, like many other file operations used in the test setup phase, I am using execFileSync. Update golang/vscode-go#6 Change-Id: Id075827ab8ebd955f7a86460aaa7ea4e0e7cd183 GitHub-Last-Rev: 6222158 GitHub-Pull-Request: golang/vscode-go#8 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/223177 Reviewed-by: Andrew Bonventre <[email protected]> * test/integration: resolve gopath in suiteSetup hook
stamblerre
changed the title
Tests shouldn't depend on source code in GOPATH
test: remove dependency on source code in GOPATH
May 11, 2020
stamblerre
added
NeedsFix
The path to resolution is known, but the work has not been done.
chore/testing
issues related to bugs in test, CI setup
labels
Jun 3, 2020
Change https://golang.org/cl/244771 mentions this issue: |
hyangah
added a commit
to hyangah/vscode-go
that referenced
this issue
Jul 24, 2020
Tests involving vendoring assumed that the source code of github.com/rogpeppe/godef and github.com/ramya-rao-a/go-outline is already checked out under GOPATH or toolsGopath. Since we install tools in modules mode, that is no longer true. This CL removes the assumption but adds a test fixture 'vendoring' that contains a vendor directory. Update golang#6 Change-Id: Id0e07ee3bd6a689c73652b306e7f6b3ed705bf72
hyangah
added a commit
to hyangah/vscode-go
that referenced
this issue
Jul 24, 2020
Tests do not need the source code of some tools. Build all tools in modules mode as the extension does. Also, remove explicit setting of GOPATH for testing. Fixes golang#6 Change-Id: Ifff7262bd0debece5781ac73c091ba9d15acc440
Change https://golang.org/cl/244772 mentions this issue: |
gopherbot
pushed a commit
that referenced
this issue
Jul 28, 2020
Tests involving vendoring assumed that the source code of github.com/rogpeppe/godef and github.com/ramya-rao-a/go-outline is already checked out under GOPATH or toolsGopath. Since we install tools in modules mode, that is no longer true. This CL removes the assumption but adds a test fixture 'vendoring' that contains a vendor directory. Update #6 Change-Id: Id0e07ee3bd6a689c73652b306e7f6b3ed705bf72 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/244771 Run-TryBot: Hyang-Ah Hana Kim <[email protected]> TryBot-Result: kokoro <[email protected]> Reviewed-by: Rebecca Stambler <[email protected]>
Closed
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
chore/testing
issues related to bugs in test, CI setup
FrozenDueToAge
NeedsFix
The path to resolution is known, but the work has not been done.
Current tests require GOPATH env var to be explicitly set
(
vscode-go/test/integration/extension.test.ts
Line 43 in 341a4ff
and depend on source code preexisting under GOPATH/src.
(
vscode-go/test/integration/extension.test.ts
Line 663 in 341a4ff
That is not ideal. Fix that.
The text was updated successfully, but these errors were encountered: