mirror of
https://github.com/kemko/nomad.git
synced 2026-01-02 00:15:43 +03:00
Golang 1.13 introduced a change in test flag parsing: > testing > ... > Testing flags are now registered in the new Init function, which is invoked by the generated main function for the test. As a result, testing flags are now only registered when running a test binary, and packages that call flag.Parse during package initialization may cause tests to fail. https://golang.org/doc/go1.13#testing Here, we ensure that e2e framework parsing occur in TestMain, by only initializing Framework at Run invocation.