Merge pull request #10263 from johncming/raftstorage

raft:  add a test case in TestStorageAppend
This commit is contained in:
Xiang Li 2018-11-15 22:01:06 +08:00 committed by GitHub
commit c2d023ce74
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -210,6 +210,11 @@ func TestStorageAppend(t *testing.T) {
werr error werr error
wentries []pb.Entry wentries []pb.Entry
}{ }{
{
[]pb.Entry{{Index: 1, Term: 1}, {Index: 2, Term: 2}},
nil,
[]pb.Entry{{Index: 3, Term: 3}, {Index: 4, Term: 4}, {Index: 5, Term: 5}},
},
{ {
[]pb.Entry{{Index: 3, Term: 3}, {Index: 4, Term: 4}, {Index: 5, Term: 5}}, []pb.Entry{{Index: 3, Term: 3}, {Index: 4, Term: 4}, {Index: 5, Term: 5}},
nil, nil,