golang / vscode-go

Go extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=golang.Go
Other
3.89k stars 755 forks source link

Polishing Go companion integration #3597

Open hyangah opened 4 days ago

hyangah commented 4 days ago

cc @firelizzard18

firelizzard18 commented 3 days ago

The legacy code lens had package-level and file-level tests codelenses placed around the "package" directive. Reevaluate if we want them in the Go Companion.

This is doable. In the current implementation there is a one-to-one correspondence between code lens and test item. Depending on the user's configuration, a test item may not exist for a given file or package. It may be best to implement these with a "run all tests in " command where the scope is a string (really: is not a test item) to push test item resolution onto the command implementation. IIRC, I chose not to implement "run file/packages tests" because it was a non-trivial amount of work and unclear if it was needed.

Consider the "running test" progress status bar when triggering a test run using the code lens. After clicking the codelens, it's not very clear whether the test is running or not.

I'm not clear on what you mean by the "running test" progress status bar. Are you referring to a vscode-go status bar? If so, interacting with that from Go Companion would be tricky I think.

firelizzard18 commented 2 days ago

Also: