Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@catatsuy
Created September 23, 2017 05:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save catatsuy/349f98ae093c66ae753e7543dd86fe67 to your computer and use it in GitHub Desktop.
Save catatsuy/349f98ae093c66ae753e7543dd86fe67 to your computer and use it in GitHub Desktop.
func TestMain(m *testing.M) {
d, err := ioutil.TempDir("", "fortest")
if err != nil {
log.Fatal(err)
}
setup(d)
code := m.Run()
clean(d)
os.Exit(code)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment