From cdd5887b77c72aa18276a6d361dd5be184bda03c Mon Sep 17 00:00:00 2001 From: Kristen Carlson Accardi Date: Wed, 27 Jul 2016 11:34:59 -0700 Subject: [PATCH] testutil: call flag.Parse in TestMain Because this test code is using ssntp, which uses glog, you must call flag.Parse prior to using ssntp. Signed-off-by: Kristen Carlson Accardi --- testutil/client_server_test.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/testutil/client_server_test.go b/testutil/client_server_test.go index d02f6fcff..fb1882977 100644 --- a/testutil/client_server_test.go +++ b/testutil/client_server_test.go @@ -17,6 +17,7 @@ package testutil_test import ( + "flag" "fmt" "os" "testing" @@ -558,6 +559,10 @@ func TestPublicIPAssigned(t *testing.T) { func TestMain(m *testing.M) { var err error + // anything that uses ssntp must call flag.Parse first + // due to glog. + flag.Parse() + // start server StartTestServer(&server)