Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

test: clean up test-loop-handles.c

  • Loading branch information
bnoordhuis committed May 29, 2012
1 parent ec0c7b8 commit 12ee388cd9d8578ef4b403e3b8144611ecd7c513
Showing with 0 additions and 17 deletions.
  1. +0 −17 test/test-loop-handles.c
@@ -208,11 +208,6 @@ static void check_cb(uv_check_t* handle, int status) {
ASSERT(handle == &check_handle);
ASSERT(status == 0);

/* XXX
ASSERT(idles_1_active == 0);
ASSERT(idle_2_is_active == 0);
*/

if (loop_iteration < ITERATIONS) {
/* Make some idle watchers active */
for (i = 0; i < 1 + (loop_iteration % IDLE_COUNT); i++) {
@@ -250,9 +245,6 @@ static void prepare_2_cb(uv_prepare_t* handle, int status) {
ASSERT(handle == &prepare_2_handle);
ASSERT(status == 0);

/* XXX ASSERT(idles_1_active == 0); */
/* XXX ASSERT(idle_2_is_active == 0); */

/* prepare_2 gets started by prepare_1 when (loop_iteration % 2 == 0), */
/* and it stops itself immediately. A started watcher is not queued */
/* until the next round, so when this callback is made */
@@ -274,11 +266,6 @@ static void prepare_1_cb(uv_prepare_t* handle, int status) {
ASSERT(handle == &prepare_1_handle);
ASSERT(status == 0);

/* XXX
ASSERT(idles_1_active == 0);
ASSERT(idle_2_is_active == 0);
*/

if (loop_iteration % 2 == 0) {
r = uv_prepare_start(&prepare_2_handle, prepare_2_cb);
ASSERT(r == 0);
@@ -340,12 +327,8 @@ TEST_IMPL(loop_handles) {
ASSERT(check_close_cb_called == 1);

/* idle_1_cb should be called a lot */
/* XXX ASSERT(idle_1_cb_called >= ITERATIONS * IDLE_COUNT * 2); */
ASSERT(idle_1_close_cb_called == IDLE_COUNT);
/* XXX ASSERT(idles_1_active == 0); */

/* XXX ASSERT(idle_2_cb_started >= ITERATIONS); */
/* XXX ASSERT(idle_2_cb_called == idle_2_cb_started); */
ASSERT(idle_2_close_cb_called == idle_2_cb_started);
ASSERT(idle_2_is_active == 0);

0 comments on commit 12ee388

Please sign in to comment.
You can’t perform that action at this time.