On Wed, Mar 19, 2014 at 3:44 PM, Brad Fitzpatrick <
brad...@golang.org> wrote:
> foo.go and foo_test.go should both be in package foo if possible.
I actually prefer to have things in package foo_test if possible. It
helps making it clear what is whiteboxed and what is not, and also
makes the use of the package in tests look closer to how people will
be interacting with the package in the wild, which often helps
improving naming while the API is being put in place. It also means
that handling circular imports is not an exception.
YMMV
gustavo @
http://niemeyer.net