mirror of
https://github.com/talent-plan/tinykv.git
synced 2025-03-15 20:31:03 +08:00
Fix TestRecvMessageType_MsgRequestVote2AA (#245)
Provide with valid peers so that responses will not be ignored.
This commit is contained in:
parent
eb173f0df1
commit
2f698ab6e3
@ -634,7 +634,7 @@ func TestRecvMessageType_MsgRequestVote2AA(t *testing.T) {
|
||||
}
|
||||
|
||||
for i, tt := range tests {
|
||||
sm := newTestRaft(1, []uint64{1}, 10, 1, NewMemoryStorage())
|
||||
sm := newTestRaft(1, []uint64{1, 2}, 10, 1, NewMemoryStorage())
|
||||
sm.State = tt.state
|
||||
sm.Vote = tt.voteFor
|
||||
sm.RaftLog = newLog(newMemoryStorageWithEnts([]pb.Entry{{}, {Index: 1, Term: 2}, {Index: 2, Term: 2}}))
|
||||
|
Loading…
Reference in New Issue
Block a user