Fix TestCertificateDNSUpdatedInvalidPrivateKey #6433

Merged
merged 2 commits into from Oct 12, 2016

Conversation

Projects
None yet
3 participants
Contributor

mjs commented Oct 12, 2016

This test contained an easy to reproduce race. The way it was waiting for the certificate updates meant that it would often end up seeing the certificate before the update was happened causing certificate parsing to fail.

The test has been rearranged to eliminate the race and the polling for changes. The certificate in the agent's config is now only checked once it is known that agent startup has occurred.

QA

The problem was easy to trigger with the stress test helper before (in a handful of iterations). It always passes now.

mjs added some commits Oct 12, 2016

Fix TestCertificateDNSUpdatedInvalidPrivateKey
This test contained an easy to reproduce race. The way it was waiting
for the certificate updates meant that it would often end up seeing the
certificate before the update was happened causing certificate parsing
to fail.

The test has been rearranged to eliminate the race and the polling for
changes. The certificate in the agent's config is now only checked once
it is known that agent startup has occurred.
Speed up certificate update tests
Waiting for State to be opened instead of certupdater startup takes 3s
off each of the related tests.
Contributor

mjs commented Oct 12, 2016

$$merge$$

Contributor

jujubot commented Oct 12, 2016

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

@jujubot jujubot merged commit 3571b6b into juju:master Oct 12, 2016

@mjs mjs deleted the mjs:1631990-TestCertificateDNSUpdatedInvalidPrivateKey-fix branch Oct 12, 2016

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