Changeset 12748 for tests/SystemQueue-tests.cc
- Timestamp:
- Mar 5, 2014, 7:17:47 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tests/SystemQueue-tests.cc
r12747 r12748 6 6 7 7 8 TEST(SystemQueue, Test1) 8 /** 9 * Tests if the SystemQueue is initialized empty and not running. 10 */ 11 TEST(SystemQueue, Instantiation) 12 { 13 SystemQueue& sysq = SystemQueue::instance(); 14 15 EXPECT_FALSE( sysq.isRunning() ); 16 EXPECT_TRUE( sysq.isEmpty() ); 17 } 18 19 20 /** 21 * Tests whether calling the SystemQueue::instance() always returns the same object. 22 * 23 * NOTE: This is an easy case, since this is the same compile unit.. 24 * But can't hurt to test it anyway. 25 */ 26 TEST(SystemQueue, Singleton) 9 27 { 10 28 SystemQueue& sysq = SystemQueue::instance(); 11 29 SystemQueue& sysq2 = SystemQueue::instance(); 12 13 ASSERT_FALSE( sysq.isRunning() );30 31 // cout << &sysq << endl; 14 32 ASSERT_TRUE( &sysq == &sysq2 ); 15 33 } 34 35
Note:
See TracChangeset
for help on using the changeset viewer.