worker/peergrouper: Fix data race in tests #5225

Merged
merged 1 commit into from Apr 20, 2016

Conversation

Projects
None yet
2 participants
Contributor

mjs commented Apr 20, 2016

TestHasVoteMaintainedEvenWhenReplicaSetFails was neglecting to stop one of the workers it started. The leaked worker would read of variables which were being patched by later tests in the suite. The
race detector would occasionally pick this up, depending on timing.

Drive-by: standardised on the workertest.CleanKill helper for shutting down the workers throughout the suite.

Fixes LP #1467715.

(Review request: http://reviews.vapour.ws/r/4650/)

worker/peergrouper: Fix data race in tests
TestHasVoteMaintainedEvenWhenReplicaSetFails was neglecting to stop
one of the workers it started. The leaked worker would read of
variables which were being patched by later tests in the suite. The
race detector would occasionally pick this up, depending on timing.

Drive-by: standardised on the workertest.CleanKill helper for shutting
down the workers throughout the suite.
Contributor

mjs commented Apr 20, 2016

$$merge$$

Contributor

jujubot commented Apr 20, 2016

Status: merge request accepted. Url: http://juju-ci.vapour.ws:8080/job/github-merge-juju

@jujubot jujubot merged commit 7f0355b into juju:master Apr 20, 2016

@mjs mjs deleted the mjs:1467715-peergrouper-test-race branch Apr 20, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment