=== RUN Test_Foo
--- PASS: Test_Foo (0.00s)
ok _/some/dir 0.002s
Official documentation for Go testing package states, that go test
automates execution of any function of the form func TestXxx(*testing.T) where Xxx can be any alphanumeric string (but the first letter must not be in [a-z]) and serves to identify the test routine.
There are tons of open-source go projects that use _ (underscore) in tests names (although all Google projects I've seen so far do follow these naming guidelines), yet _ is not alphanumeric and, according to the documentation, should not work.
I believe either this statement in documentation has to be clarified or go test behavior has to be adjusted to conform to the documentation (unlikely, considering how ubiquitous _ became)
The text was updated successfully, but these errors were encountered: