Hi, Every 6 months or so a developer on our team will inadvertently import a package that establishes an import chain from a production binary to the 'testing' package. This is a potential problem for a few reasons. It makes the binaries larger, it pollutes the cli flags with testing flags, it increases the risk that test code might actually get run, and it includes package Init() functions that are ordinarily only included in tests.
We could build some relatively simple tests to check binaries for this. For example we could check the output of `$BIN --help` for the existing of test flags. I'm wondering if the go tooling can/should do something to prevent or detect this? Can/should this be a `go vet` rule to detect main packages that end up importing 'testing'? Or would this make sense as an external tool, and does one already exist? Thanks! brian -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.