Tests needing to detect when environment is fully ready
Stuart Bishop
stuart.bishop at canonical.com
Tue May 28 10:21:51 UTC 2013
Hi.
I'm writing tests for the PostgreSQL charm but have hit a road block.
I'm happily spawning units and relating them together, but I can't
work out a way of waiting until all the hooks have finished running
and I can actually proceed to check that things are actually working.
I think I can tell from juju status that relations have been joined,
but I can't tell when all the hand shaking has completed and the
relations are actually supposed to be usable.
At the moment, the work around is to sleep for a while, but
unfortunately that needs to be several minutes and even then not that
reliable if provisioning or the instance is going slow.
Can anyone help me? I think the best approach is to expose the list of
hooks running or scheduled to be run. The test suite is Python and I'm
currently using juju 0.7.
--
Stuart Bishop <stuart.bishop at canonical.com>
More information about the Juju
mailing list