Changeset 9547 for code/branches/testing/test
- Timestamp:
- Mar 12, 2013, 10:05:25 PM (12 years ago)
- Location:
- code/branches/testing/test/util/output
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/testing/test/util/output/ConsoleWriterTest.cc
r9545 r9547 66 66 { 67 67 OutputManager::getInstanceAndCreateListeners(); 68 EXPECT_EQ(std::cout, OutputManager::getInstance().getConsoleWriter() .getOutputStream());68 EXPECT_EQ(std::cout, OutputManager::getInstance().getConsoleWriter()->getOutputStream()); 69 69 } 70 70 } -
code/branches/testing/test/util/output/OutputManagerTest.cc
r9545 r9547 54 54 TEST(OutputManagerTest, GetInstanceDoesNotCreateDefaultListeners) 55 55 { 56 EXPECT_TRUE(NULL == &OutputManager::getInstance().getMemoryWriter());57 EXPECT_TRUE(NULL == &OutputManager::getInstance().getConsoleWriter());58 EXPECT_TRUE(NULL == &OutputManager::getInstance().getLogWriter());56 EXPECT_TRUE(NULL == OutputManager::getInstance().getMemoryWriter()); 57 EXPECT_TRUE(NULL == OutputManager::getInstance().getConsoleWriter()); 58 EXPECT_TRUE(NULL == OutputManager::getInstance().getLogWriter()); 59 59 } 60 60 … … 62 62 TEST(OutputManagerTest, GetInstanceAndCreateListenersCreatesDefaultListeners) 63 63 { 64 EXPECT_TRUE(NULL != &OutputManager::getInstanceAndCreateListeners().getMemoryWriter());65 EXPECT_TRUE(NULL != &OutputManager::getInstanceAndCreateListeners().getConsoleWriter());66 EXPECT_TRUE(NULL != &OutputManager::getInstanceAndCreateListeners().getLogWriter());64 EXPECT_TRUE(NULL != OutputManager::getInstanceAndCreateListeners().getMemoryWriter()); 65 EXPECT_TRUE(NULL != OutputManager::getInstanceAndCreateListeners().getConsoleWriter()); 66 EXPECT_TRUE(NULL != OutputManager::getInstanceAndCreateListeners().getLogWriter()); 67 67 } 68 68 … … 70 70 TEST(OutputManagerTest, GetInstanceAndCreateListenersDoesNotCreateDefaultListenersTwice) 71 71 { 72 MemoryWriter* memoryWriter = &OutputManager::getInstanceAndCreateListeners().getMemoryWriter();73 ConsoleWriter* consoleWriter = &OutputManager::getInstanceAndCreateListeners().getConsoleWriter();74 LogWriter* logWriter = &OutputManager::getInstanceAndCreateListeners().getLogWriter();75 76 EXPECT_TRUE(memoryWriter == &OutputManager::getInstanceAndCreateListeners().getMemoryWriter());77 EXPECT_TRUE(consoleWriter == &OutputManager::getInstanceAndCreateListeners().getConsoleWriter());78 EXPECT_TRUE(logWriter == &OutputManager::getInstanceAndCreateListeners().getLogWriter());72 MemoryWriter* memoryWriter = OutputManager::getInstanceAndCreateListeners().getMemoryWriter(); 73 ConsoleWriter* consoleWriter = OutputManager::getInstanceAndCreateListeners().getConsoleWriter(); 74 LogWriter* logWriter = OutputManager::getInstanceAndCreateListeners().getLogWriter(); 75 76 EXPECT_TRUE(memoryWriter == OutputManager::getInstanceAndCreateListeners().getMemoryWriter()); 77 EXPECT_TRUE(consoleWriter == OutputManager::getInstanceAndCreateListeners().getConsoleWriter()); 78 EXPECT_TRUE(logWriter == OutputManager::getInstanceAndCreateListeners().getLogWriter()); 79 79 } 80 80 -
code/branches/testing/test/util/output/OutputStreamTest.cc
r9545 r9547 64 64 { 65 65 // disable MemoryWriter because otherwise we would always accept all output 66 OutputManager::getInstance().getMemoryWriter() .disable();66 OutputManager::getInstance().getMemoryWriter()->disable(); 67 67 68 68 { … … 140 140 { 141 141 // disable MemoryWriter because otherwise we would always accept all output 142 OutputManager::getInstanceAndCreateListeners().getMemoryWriter() .disable();142 OutputManager::getInstanceAndCreateListeners().getMemoryWriter()->disable(); 143 143 144 144 OutputStream stream;
Note: See TracChangeset
for help on using the changeset viewer.