Clean up locking, remove Voter/Candidate entanglement

This commit is contained in:
Ian Gulliver
2023-06-07 22:48:38 -07:00
parent 0bcd5a0b06
commit 38f232f7aa
4 changed files with 34 additions and 70 deletions

View File

@@ -66,7 +66,7 @@ func TestPartialVotes(t *testing.T) {
ts := NewTestSystem(t, 3)
defer ts.Stop()
ts.Voter(0).Stop()
ts.Proxy(0).SetRefuse(true)
require.False(t, ts.Candidate(0).IsLeader())
require.False(t, ts.Candidate(1).IsLeader())