tests.test_hear_cleanup
Module Contents
Classes
Test suite for verifying the cleanup behavior of the multicast hearing mechanism. |
Data
API
- tests.test_hear_cleanup.__module__[source]
‘tests’
- class tests.test_hear_cleanup.HearCleanupTestSuite(methodName='runTest')[source][source]
Bases:
context.BasicUsageTestSuiteTest suite for verifying the cleanup behavior of the multicast hearing mechanism.
This suite tests that the
McastHEARclass correctly releases resources and terminates gracefully when the hearing process receives a “STOP Test” message. It ensures that sockets are properly closed and no lingering processes remain after execution, adhering to the expected cleanup protocols.Initialization
Create an instance of the class that will use the named test method when executed. Raises a ValueError if the instance does not have a method with the specified name.
- __module__[source]
‘tests.test_hear_cleanup’
- __name__[source]
‘tests.test_hear_cleanup.HearCleanupTestSuite’
- QUICK_JOIN_TIMEOUT[source]
1
- ERROR_JOIN_TIMEOUT[source]
3
- FINAL_JOIN_TIMEOUT[source]
15
- test_cleanup_on_exit()[source][source]
Test proper cleanup of McastHEAR when receiving STOP message.
Prerequisites: - Available test port (self._the_test_port) - Multicast group 224.0.0.1 accessible
Expected behavior: 1. Start McastHEAR process in daemon mode 2. Send “STOP Test” message 3. Verify process terminates cleanly 4. Ensure all resources are released
Success criteria: - Process exits with code 0 - No lingering processes or sockets