pulsar.client.test package
Submodules
pulsar.client.test.check module
Script used to run an example job against a running Pulsar server.
Exercises various features both the Pulsar client and server.
- class pulsar.client.test.check.ClientInfo(client, client_manager)
Bases:
tuple- client
Alias for field number 0
- client_manager
Alias for field number 1
- pulsar.client.test.check.client_info(options, client_options, job_id=None)[source]
From command-line arguments
options- extract options related to build a client manager and build it. Then get a client with supplied client options and optional job id.
- pulsar.client.test.check.extract_client_options(options)[source]
Exract options explicitly related to build client from configured client manager.
pulsar.client.test.test_common module
For code shared between test_utils.py and check.py. Not sure this is the best place - but check needs to not depend on test_utils so run_client_tests can execute without webob dependency.
pulsar.client.test.test_relay_transport module
Tests for the relay transport implementation.
Tests retry logic and message ID tracking functionality.
- class pulsar.client.test.test_relay_transport.TestMessageIDTracking[source]
Bases:
objectTest message ID tracking functionality.
- class pulsar.client.test.test_relay_transport.TestRetryLogic(methodName='runTest')[source]
Bases:
TestCaseTest retry logic with exponential backoff.
- test_post_message_does_not_retry_on_400_error()[source]
Test that post_message does NOT retry on 4xx client errors.
- test_post_message_retries_on_500_error(mock_sleep)[source]
Test that post_message retries on 5xx server errors.
- test_post_message_retries_on_connection_error(mock_sleep)[source]
Test that post_message retries indefinitely on connection errors.