mardi 18 juillet 2017

panic while running go subtests with go test -r TestXYZ

I'm developing a web app which uses mysql as its database. Within this app I have a function named XYZ that takes an slice, loops over it and calculates something and returns a float64. XYZ function does not use mysql connection in way or shape.

I have a _test.go file inside the package that XYZ function is defined. Inside _test.go file I have TestXYZ function that calls XYZ (pretty normal go testing procedure).

When I run go test -r TestXYZ I get panic: Failed to connect Mysql.

Aucun commentaire:

Enregistrer un commentaire