From 62a8df304ac127f6e3c756f4ed123a9a3fb9a09a Mon Sep 17 00:00:00 2001 From: Xiang Li Date: Mon, 24 Nov 2014 11:10:02 -0800 Subject: [PATCH] raft: fix error message in TestLogRestore --- raft/log_test.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/raft/log_test.go b/raft/log_test.go index 8d7b93b4e..9878102aa 100644 --- a/raft/log_test.go +++ b/raft/log_test.go @@ -505,9 +505,8 @@ func TestLogRestore(t *testing.T) { storage.ApplySnapshot(pb.Snapshot{Metadata: snap}) raftLog := newLog(storage) - // only has the guard entry if len(raftLog.allEntries()) != 0 { - t.Errorf("len = %d, want 1", len(raftLog.allEntries())) + t.Errorf("len = %d, want 0", len(raftLog.allEntries())) } if raftLog.firstIndex() != index+1 { t.Errorf("firstIndex = %d, want %d", raftLog.firstIndex(), index+1)