engine: test: Pass in the go test verbose flag
This hooks up our debug variable to the go test verbose flag.
This commit is contained in:
@@ -222,7 +222,7 @@ func (obj *testGrouper) EdgeMerge(e1, e2 pgraph.Edge) pgraph.Edge {
|
|||||||
|
|
||||||
// helper function
|
// helper function
|
||||||
func runGraphCmp(t *testing.T, g1, g2 *pgraph.Graph) {
|
func runGraphCmp(t *testing.T, g1, g2 *pgraph.Graph) {
|
||||||
debug := true
|
debug := testing.Verbose() // set via the -test.v flag to `go test`
|
||||||
logf := func(format string, v ...interface{}) {
|
logf := func(format string, v ...interface{}) {
|
||||||
t.Logf("test: "+format, v...)
|
t.Logf("test: "+format, v...)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func fakeInit(t *testing.T) *engine.Init {
|
func fakeInit(t *testing.T) *engine.Init {
|
||||||
debug := true
|
debug := testing.Verbose() // set via the -test.v flag to `go test`
|
||||||
logf := func(format string, v ...interface{}) {
|
logf := func(format string, v ...interface{}) {
|
||||||
t.Logf("test: "+format, v...)
|
t.Logf("test: "+format, v...)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ func TestFileAutoEdge1(t *testing.T) {
|
|||||||
t.Errorf("should have 0 edges instead of: %d", i)
|
t.Errorf("should have 0 edges instead of: %d", i)
|
||||||
}
|
}
|
||||||
|
|
||||||
debug := true
|
debug := testing.Verbose() // set via the -test.v flag to `go test`
|
||||||
logf := func(format string, v ...interface{}) {
|
logf := func(format string, v ...interface{}) {
|
||||||
t.Logf("test: "+format, v...)
|
t.Logf("test: "+format, v...)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user