You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
(I proposed this and a few other suggestions here but since I haven't got any feedback, I am submitting this one as a separate issue here)
Hi,
It would be nice to have an ability to list ALL tests and/or fuzzing harnesses in ALL packages/subpackages of a given module/project with the go test -list ./... command.
Currently, this reports no Go files in /Users/user/go/src/github.com/xxx/yyy for me and a workaround for this can be iterating over all directories manually and listing all the tests, for example with the following command:
find . -type d -exec bash -c "cd {} && go test -list . && cd -" \;
Also, it seems that Go commands can traverse all subpackages since go list -test ./... seems to be able to do that, but the problem is it does not list tests (or fuzzing harnesses) but only the test binaries.
The proposed feature would be useful for automatic fuzzing, e.g., to be able to list all harnesses and spawn fuzzers on the fly based on the list.
Additionally, it would be nice to be able to control the output somehow: what matters the most is 1) test package name, 2) test/fuzz harness name, since this is what is eventually needed to run the test/fuzzing harness. All other output like ok github.com/xxx/yyy/subpath1/subpath2 0.333s is not useful at all.
The text was updated successfully, but these errors were encountered:
note the -list takes an argument
so go test -list . ./....
Oh interesting, that works, thanks. Though, this was kinda unexpected to me as I was used that many other commands and Go tools accept just "./...", heh.
it'll never be able to list everything, subtests require code execution to find.
I'm personally okay with code execution as long as I would get the whole list ;).
(I proposed this and a few other suggestions here but since I haven't got any feedback, I am submitting this one as a separate issue here)
Hi,
It would be nice to have an ability to list ALL tests and/or fuzzing harnesses in ALL packages/subpackages of a given module/project with the
go test -list ./...
command.Currently, this reports
no Go files in /Users/user/go/src/github.com/xxx/yyy
for me and a workaround for this can be iterating over all directories manually and listing all the tests, for example with the following command:Also, it seems that Go commands can traverse all subpackages since
go list -test ./...
seems to be able to do that, but the problem is it does not list tests (or fuzzing harnesses) but only the test binaries.The proposed feature would be useful for automatic fuzzing, e.g., to be able to list all harnesses and spawn fuzzers on the fly based on the list.
Additionally, it would be nice to be able to control the output somehow: what matters the most is 1) test package name, 2) test/fuzz harness name, since this is what is eventually needed to run the test/fuzzing harness. All other output like
ok github.com/xxx/yyy/subpath1/subpath2 0.333s
is not useful at all.The text was updated successfully, but these errors were encountered: