Lines Matching refs:alarm
76 alarm_t* alarm = alarm_new("alarm_test.test_new_free_simple"); in TEST_F() local
77 ASSERT_TRUE(alarm != NULL); in TEST_F()
78 alarm_free(alarm); in TEST_F()
84 alarm_t* alarm = alarm_new("alarm_test.test_simple_cancel"); in TEST_F() local
85 alarm_cancel(alarm); in TEST_F()
86 alarm_free(alarm); in TEST_F()
90 alarm_t* alarm = alarm_new("alarm_test.test_cancel"); in TEST_F() local
91 alarm_set(alarm, 10, cb, NULL); in TEST_F()
92 alarm_cancel(alarm); in TEST_F()
98 alarm_free(alarm); in TEST_F()
102 alarm_t* alarm = alarm_new("alarm_test.test_cancel_idempotent"); in TEST_F() local
103 alarm_set(alarm, 10, cb, NULL); in TEST_F()
104 alarm_cancel(alarm); in TEST_F()
105 alarm_cancel(alarm); in TEST_F()
106 alarm_cancel(alarm); in TEST_F()
107 alarm_free(alarm); in TEST_F()
111 alarm_t* alarm = alarm_new("alarm_test.test_set_short"); in TEST_F() local
113 alarm_set(alarm, 10, cb, NULL); in TEST_F()
123 alarm_free(alarm); in TEST_F()
127 alarm_t* alarm = alarm_new_periodic("alarm_test.test_set_short_periodic"); in TEST_F() local
129 alarm_set(alarm, 10, cb, NULL); in TEST_F()
140 alarm_cancel(alarm); in TEST_F()
143 alarm_free(alarm); in TEST_F()
147 alarm_t* alarm = alarm_new_periodic("alarm_test.test_set_zero_periodic"); in TEST_F() local
149 alarm_set(alarm, 0, cb, NULL); in TEST_F()
159 alarm_cancel(alarm); in TEST_F()
162 alarm_free(alarm); in TEST_F()
166 alarm_t* alarm = alarm_new("alarm_test.test_set_long"); in TEST_F() local
167 alarm_set(alarm, TIMER_INTERVAL_FOR_WAKELOCK_IN_MS + EPSILON_MS, cb, NULL); in TEST_F()
177 alarm_free(alarm); in TEST_F()
181 alarm_t* alarm[2] = {alarm_new("alarm_test.test_set_short_short_0"), in TEST_F() local
184 alarm_set(alarm[0], 10, cb, NULL); in TEST_F()
185 alarm_set(alarm[1], 20, cb, NULL); in TEST_F()
200 alarm_free(alarm[0]); in TEST_F()
201 alarm_free(alarm[1]); in TEST_F()
205 alarm_t* alarm[2] = {alarm_new("alarm_test.test_set_short_long_0"), in TEST_F() local
208 alarm_set(alarm[0], 10, cb, NULL); in TEST_F()
209 alarm_set(alarm[1], 10 + TIMER_INTERVAL_FOR_WAKELOCK_IN_MS + EPSILON_MS, cb, in TEST_F()
225 alarm_free(alarm[0]); in TEST_F()
226 alarm_free(alarm[1]); in TEST_F()
230 alarm_t* alarm[2] = {alarm_new("alarm_test.test_set_long_long_0"), in TEST_F() local
233 alarm_set(alarm[0], TIMER_INTERVAL_FOR_WAKELOCK_IN_MS + EPSILON_MS, cb, NULL); in TEST_F()
234 alarm_set(alarm[1], 2 * (TIMER_INTERVAL_FOR_WAKELOCK_IN_MS + EPSILON_MS), cb, in TEST_F()
250 alarm_free(alarm[0]); in TEST_F()
251 alarm_free(alarm[1]); in TEST_F()
255 alarm_t* alarm = alarm_new("alarm_test.test_is_scheduled"); in TEST_F() local
258 EXPECT_FALSE(alarm_is_scheduled(alarm)); in TEST_F()
259 alarm_set(alarm, TIMER_INTERVAL_FOR_WAKELOCK_IN_MS + EPSILON_MS, cb, NULL); in TEST_F()
260 EXPECT_TRUE(alarm_is_scheduled(alarm)); in TEST_F()
267 EXPECT_FALSE(alarm_is_scheduled(alarm)); in TEST_F()
271 alarm_free(alarm); in TEST_F()
341 alarm_t* alarm = alarm_new(alarm_name.c_str()); in TEST_F() local
342 alarm_set(alarm, 0, cb, NULL); in TEST_F()
343 alarm_free(alarm); in TEST_F()
355 alarm_t* alarm = alarm_new("alarm_test.test_delete_during_callback"); in TEST_F() local
356 alarm_set(alarm, 0, remove_cb, alarm); in TEST_F()