|
|
@@ -306,20 +306,20 @@ func TestNodeStart(t *testing.T) {
|
|
|
wants := []Ready{
|
|
|
{
|
|
|
SoftState: &SoftState{Lead: 1, Nodes: []uint64{1}, RaftState: StateLeader},
|
|
|
- HardState: raftpb.HardState{Term: 1, Commit: 2},
|
|
|
+ HardState: raftpb.HardState{Term: 2, Commit: 2},
|
|
|
Entries: []raftpb.Entry{
|
|
|
{Type: raftpb.EntryConfChange, Term: 1, Index: 1, Data: ccdata},
|
|
|
- {Term: 1, Index: 2},
|
|
|
+ {Term: 2, Index: 2},
|
|
|
},
|
|
|
CommittedEntries: []raftpb.Entry{
|
|
|
{Type: raftpb.EntryConfChange, Term: 1, Index: 1, Data: ccdata},
|
|
|
- {Term: 1, Index: 2},
|
|
|
+ {Term: 2, Index: 2},
|
|
|
},
|
|
|
},
|
|
|
{
|
|
|
- HardState: raftpb.HardState{Term: 1, Commit: 3},
|
|
|
- Entries: []raftpb.Entry{{Term: 1, Index: 3, Data: []byte("foo")}},
|
|
|
- CommittedEntries: []raftpb.Entry{{Term: 1, Index: 3, Data: []byte("foo")}},
|
|
|
+ HardState: raftpb.HardState{Term: 2, Commit: 3},
|
|
|
+ Entries: []raftpb.Entry{{Term: 2, Index: 3, Data: []byte("foo")}},
|
|
|
+ CommittedEntries: []raftpb.Entry{{Term: 2, Index: 3, Data: []byte("foo")}},
|
|
|
},
|
|
|
}
|
|
|
storage := NewMemoryStorage()
|