diff options
author | Clément Bénier <clement.benier@iot.bzh> | 2018-08-21 17:56:10 +0200 |
---|---|---|
committer | Clément Bénier <clement.benier@iot.bzh> | 2018-08-21 17:56:10 +0200 |
commit | b1d091a8c6b2269601a1683e963d0e382cd0f7f6 (patch) | |
tree | ec60f14ec47211e929d144bde128fbbff5f7c0dc /test/xdsserver_test.go | |
parent | 4192072863ac0997b0c3cb4131ea913e6f85f83e (diff) |
test logs: hide log
logs are printable with VERBOSE != ""
Change-Id: I170aed2e73db673ba6276410b1dddd3389239457
Signed-off-by: Clément Bénier <clement.benier@iot.bzh>
Diffstat (limited to 'test/xdsserver_test.go')
-rw-r--r-- | test/xdsserver_test.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/xdsserver_test.go b/test/xdsserver_test.go index b8e98b5..89f73a6 100644 --- a/test/xdsserver_test.go +++ b/test/xdsserver_test.go @@ -47,6 +47,18 @@ var HTTPCli *common.HTTPClient var logDir string var sCli *IOSockClient +func Debug(t *testing.T, args ...interface{}) { + if os.Getenv("VERBOSE") != "" { + t.Log(args) + } +} + +func Debugf(t *testing.T, format string, args ...interface{}) { + if os.Getenv("VERBOSE") != "" { + t.Logf(format, args) + } +} + func Copy(src, dst string) error { in, err := os.Open(src) if err != nil { |