From 7c10c12ce796b528193ac2745101d5333662541c Mon Sep 17 00:00:00 2001 From: Gyuho Lee Date: Tue, 17 Apr 2018 06:13:52 -0700 Subject: [PATCH] snapshot: use /dev/null to discard server logs Signed-off-by: Gyuho Lee --- snapshot/member_test.go | 2 +- snapshot/v3_snapshot_test.go | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/snapshot/member_test.go b/snapshot/member_test.go index 6cec9aab0..6e3608a16 100644 --- a/snapshot/member_test.go +++ b/snapshot/member_test.go @@ -64,7 +64,7 @@ func TestSnapshotV3RestoreMultiMemberAdd(t *testing.T) { cfg := embed.NewConfig() cfg.Logger = "zap" - cfg.LogOutput = "discard" + cfg.LogOutput = "/dev/null" cfg.Debug = false cfg.Name = "3" cfg.InitialClusterToken = testClusterTkn diff --git a/snapshot/v3_snapshot_test.go b/snapshot/v3_snapshot_test.go index 12e665f6b..e86762a06 100644 --- a/snapshot/v3_snapshot_test.go +++ b/snapshot/v3_snapshot_test.go @@ -44,7 +44,7 @@ func TestSnapshotV3RestoreSingle(t *testing.T) { cfg := embed.NewConfig() cfg.Logger = "zap" - cfg.LogOutput = "discard" + cfg.LogOutput = "/dev/null" cfg.Debug = false cfg.Name = "s1" cfg.InitialClusterToken = testClusterTkn @@ -153,7 +153,7 @@ func createSnapshotFile(t *testing.T, kvs []kv) string { cfg := embed.NewConfig() cfg.Logger = "zap" - cfg.LogOutput = "discard" + cfg.LogOutput = "/dev/null" cfg.Debug = false cfg.Name = "default" cfg.ClusterState = "new" @@ -220,7 +220,7 @@ func restoreCluster(t *testing.T, clusterN int, dbPath string) ( for i := 0; i < clusterN; i++ { cfg := embed.NewConfig() cfg.Logger = "zap" - cfg.LogOutput = "discard" + cfg.LogOutput = "/dev/null" cfg.Debug = false cfg.Name = fmt.Sprintf("%d", i) cfg.InitialClusterToken = testClusterTkn