Skip to content
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

x/tools/gopls: migrate "test generation" features to gopls #47479

Open
n1lesh opened this issue Jul 30, 2021 · 1 comment
Open

x/tools/gopls: migrate "test generation" features to gopls #47479

n1lesh opened this issue Jul 30, 2021 · 1 comment

Comments

@n1lesh
Copy link

@n1lesh n1lesh commented Jul 30, 2021

vscode-go uses the gotests package to generate unit tests, which makes it hard to adjust the test generation behavior as mentioned here: vscode-go issue #1594.

We could move the test generation logic to gopls, which provides a few benefits,

  1. Flexibility in modifying logic around test generation. Current vscode-go implementation uses gotests as a child process to generate tests, which makes it hard to customize test generation.
  2. Reduction in the number of 3rd party tools for vscode-go. gotests package moves within gopls.

More about it here.

/cc @stamblerre

@seankhliao seankhliao changed the title gopls: Migrate "test generation" features to gopls x/tools/gopls: Migrate "test generation" features to gopls Jul 31, 2021
@gopherbot gopherbot added this to the Unreleased milestone Jul 31, 2021
@beoran
Copy link

@beoran beoran commented Jul 31, 2021

Currently, gotests is written to work as as a command only. I reccommend you would work together with @cweil and help to develop a version of gotests that also can be used as a module library, and which has the additional features you would like. This will then also benefit people who are not using gopls or VisualStudio, and want to integrate this in a different editor, like myself.

@findleyr findleyr removed this from the Unreleased milestone Aug 3, 2021
@findleyr findleyr added this to the gopls/unplanned milestone Aug 3, 2021
@stamblerre stamblerre changed the title x/tools/gopls: Migrate "test generation" features to gopls x/tools/gopls: migrate "test generation" features to gopls Sep 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants