alma::acs::logging::config::LogConfigTest Class Reference

Inheritance diagram for alma::acs::logging::config::LogConfigTest:
Inheritance graph
[legend]
Collaboration diagram for alma::acs::logging::config::LogConfigTest:
Collaboration graph
[legend]

List of all members.

Classes

class  CountingLogConfigSubscriber

Public Member Functions

 LogConfigTest ()
void testSubscriberNotification () throws LogConfigException
void testDefaultValues () throws Exception
void testGetLogConfigXml () throws Exception
void testCDBValues () throws Exception
void testInvalidCDB () throws Exception
void testDynamicChanges () throws Exception
void testLockingRemoteLevel () throws Exception

Protected Member Functions

void setUp () throws Exception
void tearDown () throws Exception

Private Member Functions

String createComponentsCdbXml (String compName, String type, String code, String container, boolean configureLogger, int minLogLevel, int minLogLevelLocal)

Private Attributes

LogConfig logConfig
Logger logger

Detailed Description

Test for LogConfig}. Does not require a running ACS environment.

Author:
hsommer

Constructor & Destructor Documentation

alma::acs::logging::config::LogConfigTest::LogConfigTest (  )  [inline]

Member Function Documentation

String alma::acs::logging::config::LogConfigTest::createComponentsCdbXml ( String  compName,
String  type,
String  code,
String  container,
boolean  configureLogger,
int  minLogLevel,
int  minLogLevelLocal 
) [inline, private]
void alma::acs::logging::config::LogConfigTest::setUp (  )  throws Exception [inline, protected]
void alma::acs::logging::config::LogConfigTest::tearDown (  )  throws Exception [inline, protected]
void alma::acs::logging::config::LogConfigTest::testCDBValues (  )  throws Exception [inline]
void alma::acs::logging::config::LogConfigTest::testDefaultValues (  )  throws Exception [inline]

Tests the config values returned from LogConfig with at most env vars for default levels being set (can be enforced by TAT!), but without CDB or other information being considered.

Also asserts that none of these calls return the original object, but instead a copy of it. This indirectly exercises the equals method.

References alma::acs::logging::config::LogConfig::getCentralizedLogger(), alma::acs::logging::config::LogConfig::getDefaultMinLogLevel(), alma::acs::logging::config::LogConfig::getDefaultMinLogLevelLocal(), alma::acs::logging::config::LogConfig::getDispatchPacketSize(), alma::acs::logging::config::LogConfig::getFlushPeriodSeconds(), alma::acs::logging::config::LogConfig::getImmediateDispatchLevel(), alma::acs::logging::config::LogConfig::getNamedLoggerConfig(), logConfig, and logger.

void alma::acs::logging::config::LogConfigTest::testDynamicChanges (  )  throws Exception [inline]
void alma::acs::logging::config::LogConfigTest::testGetLogConfigXml (  )  throws Exception [inline]
void alma::acs::logging::config::LogConfigTest::testInvalidCDB (  )  throws Exception [inline]
void alma::acs::logging::config::LogConfigTest::testLockingRemoteLevel (  )  throws Exception [inline]
void alma::acs::logging::config::LogConfigTest::testSubscriberNotification (  )  throws LogConfigException [inline]

Tests adding and removing of subscribers, and whether LogConfig#initialize(boolean) triggers correctly the notification of these subscribers.

References alma::acs::logging::config::LogConfig::addSubscriber(), alma::acs::logging::config::LogConfig::initialize(), logConfig, logger, and alma::acs::logging::config::LogConfig::removeSubscriber().


Member Data Documentation


The documentation for this class was generated from the following file:

Generated by  doxygen 1.6.2