acaeb62a4dc310f561091bd9b0f4e8f9f8aa5928
* Stop retrying if LB provisioning status reached ERROR The method `wait_for_lb_resource()` retries for 15m while the load balancer could have reached to ERROR during the provisioning in the first few minutes, this approach makes the testing take longer for no reason. This change makes the ERROR state in provisioning_status final and abort raising a ValueError() exception. More details of the provisioning_status possible states can be found at: https://docs.openstack.org/api-ref/load-balancer/v2/#provisioning-status-codes * Use LoadBalancerUnexpectedState and LoadBalancerUnrecoverableError. Drop the (re-)use of AssertionError and ValueError to identify when a load balancer status is in a state where the test needs to retry or break and fail respectively. This change introduces 2 new exceptions to be explicit of what the code is trying to do. - LoadBalancerUnexpectedState is raised when the status of the load balancer is in a state different from the one requested by the caller, but said state can be considered as transitory. - LoadBalancerUnrecoverableError is raised when the status of the load balancer is in ERROR state and said state is final for the proviniong_status property, hence retrying only delays the failure.
Zaza OpenStack Tests
This is a test library designed to be shared between the OpenStack Charms to improve code-reuse among the various components.
Usage
This example is taken from the pacemaker-remote charm's tests.yaml:
charm_name: pacemaker-remote
tests:
- zaza.openstack.charm_tests.pacemaker_remote.tests.PacemakerRemoteTest
configure:
- zaza.charm_tests.noop.setup.basic_setup
gate_bundles:
- basic
smoke_bundles:
- basic
test-requirements.txt:
git+https://github.com/openstack-charmers/zaza.git#egg=zaza
git+https://github.com/openstack-charmers/zaza-openstack-tests.git#egg=zaza.openstack
Description
Languages
Python
99.6%
Jinja
0.4%