summaryrefslogtreecommitdiffstats
path: root/test/xdsserver_test.go
diff options
context:
space:
mode:
authorClément Bénier <clement.benier@iot.bzh>2018-08-21 17:56:10 +0200
committerClément Bénier <clement.benier@iot.bzh>2018-08-21 17:56:10 +0200
commitb1d091a8c6b2269601a1683e963d0e382cd0f7f6 (patch)
treeec60f14ec47211e929d144bde128fbbff5f7c0dc /test/xdsserver_test.go
parent4192072863ac0997b0c3cb4131ea913e6f85f83e (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.go12
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 {