Created
March 5, 2014 23:57
-
-
Save jsbattig/9379341 to your computer and use it in GitHub Desktop.
ThreadPoolTimer test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TEST_F(SvcBusThreadPoolTest, SvcBusConsumer_testThreadPoolTimer) { | |
SvcBusThreadPoolTimer timer[1]; | |
int int_value = 0; | |
ASSERT_TRUE(SvcBusThreadPoolTimer_init( timer, thread_pool, &TestCallback, &int_value, 100 ) == SVCBUS_THREADPOOL_OK); | |
EXPECT_EQ(0, SvcBusThreadPoolTimer_getThreadId( timer)); | |
SvcBus_crossSleep(500); | |
EXPECT_TRUE( int_value > 0 ); | |
EXPECT_NE(0, SvcBusThreadPoolTimer_getThreadId( timer)); | |
SvcBusThreadPoolTimer_destroy( timer ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment