

Public Member Functions | |
| void | testNoOp () |
| void | testStoppingThreads () throws Exception |
| void | testUserThreadException () |
Protected Member Functions | |
| void | setUp () throws Exception |
| void | tearDown () throws Exception |
Private Member Functions | |
| void | sleep (int millis) |
Private Attributes | |
| LogRecordCollectingLogger | logger |
Tests the thread factory used by ContainerServices#getThreadFactory(), which can kill surviving user threads.
| void alma::acs::container::CleaningThreadFactoryTest::setUp | ( | ) | throws Exception [inline, protected] |
| void alma::acs::container::CleaningThreadFactoryTest::sleep | ( | int | millis | ) | [inline, private] |
References logger.
Referenced by testStoppingThreads(), and testUserThreadException().
| void alma::acs::container::CleaningThreadFactoryTest::tearDown | ( | ) | throws Exception [inline, protected] |
| void alma::acs::container::CleaningThreadFactoryTest::testNoOp | ( | ) | [inline] |
References alma::acs::container::CleaningDaemonThreadFactory::cleanUp(), and logger.
| void alma::acs::container::CleaningThreadFactoryTest::testStoppingThreads | ( | ) | throws Exception [inline] |
Creates 4 threads such that they have different behavior and status when cleanUp is called on the thread factory:
This test verifies that
References alma::acs::container::CleaningDaemonThreadFactory::cleanUp(), alma::acs::testsupport::LogRecordCollectingLogger::clearLogRecords(), alma::acs::testsupport::LogRecordCollectingLogger::getCollectedLogRecords(), logger, alma::acs::container::CleaningDaemonThreadFactory::newThread(), and sleep().
| void alma::acs::container::CleaningThreadFactoryTest::testUserThreadException | ( | ) | [inline] |
Verifies that a warning is logged when a user thread throws an otherwise uncaught exception.
References alma::acs::testsupport::LogRecordCollectingLogger::clearLogRecords(), alma::acs::testsupport::LogRecordCollectingLogger::getCollectedLogRecords(), logger, alma::acs::container::CleaningDaemonThreadFactory::newThread(), and sleep().
Referenced by setUp(), sleep(), tearDown(), testNoOp(), testStoppingThreads(), and testUserThreadException().
1.6.2