LoadBalancerBaseTest
(*args, **kwargs)[source]¶Bases: tempest.test.BaseTestCase
Base class for load balancer tests.
client_manager
¶credentials
= ['admin', 'primary', ['lb_member', 'load-balancer_member'], ['lb_member2', 'load-balancer_member'], ['lb_admin', 'load-balancer_admin']]¶src_port_number
= 32768¶used_ips
= []¶webserver1_response
= 1¶webserver2_response
= 5¶LoadBalancerBaseTestWithCompute
(*args, **kwargs)[source]¶Bases: octavia_tempest_plugin.tests.test_base.LoadBalancerBaseTest
assertConsistentResponse
(response, url, method='GET', repeat=10, redirect=False, timeout=2, conn_error=False, **kwargs)[source]¶Assert that a request to URL gets the expected response.
Parameters: |
|
---|---|
Returns: | boolean success status |
Raises: | testtools.matchers.MismatchError |
validate_URL_response
(URL, expected_status_code=200, expected_body=None, HTTPS_verify=True, client_cert_path=None, CA_certs_path=None, request_interval=5, request_timeout=300)[source]¶Check a URL response (HTTP or HTTPS).
Parameters: |
|
---|---|
Raises: |
|
Returns: | None |
wait_for_deleted_status_or_not_found
(show_client, id, status_key, check_interval, check_timeout, root_tag=None, **kwargs)[source]¶Waits for an object to reach a DELETED status or be not found (404).
Parameters: |
|
---|---|
Check_interval: | How often to check the status, in seconds. |
Check_timeout: | The maximum time, in seconds, to check the status. |
Root_tag: | The root tag on the response to remove, if any. |
Raises: |
|
Returns: | None |
wait_for_not_found
(delete_func, show_func, *args, **kwargs)[source]¶Call the delete function, then wait for it to be ‘NotFound’
Parameters: |
|
---|---|
Raises: | TimeoutException – The object did not achieve the status or ERROR in the check_timeout period. |
Returns: | None |
wait_for_spare_amps
(list_func, check_interval, check_timeout)[source]¶Waits for amphorae in spare pool.
Parameters: | list_func – The tempest service client amphora list method. Ex. cls.os_admin.amphora_client.list_amphorae |
---|---|
Check_interval: | How often to check the status, in seconds. |
Check_timeout: | The maximum time, in seconds, to check the status. |
Raises: | TimeoutException – No amphora available in spare pool in the check_timeout period. |
Returns: | A list of amphorae in spare pool. |
wait_for_status
(show_client, id, status_key, status, check_interval, check_timeout, root_tag=None, error_ok=False, **kwargs)[source]¶Waits for an object to reach a specific status.
Parameters: |
|
---|---|
Check_interval: | How often to check the status, in seconds. |
Check_timeout: | The maximum time, in seconds, to check the status. |
Root_tag: | The root tag on the response to remove, if any. |
Error_ok: | When true, ERROR status will not raise an exception. |
Raises: |
|
Returns: | The object details from the show client. |
Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.