aboutsummaryrefslogtreecommitdiff
path: root/src/testing/test_testing_peerstartup2.c
diff options
context:
space:
mode:
authorSree Harsha Totakura <totakura@in.tum.de>2013-05-07 10:54:03 +0000
committerSree Harsha Totakura <totakura@in.tum.de>2013-05-07 10:54:03 +0000
commitea931ffc94e1f8145c30c98da50cd5ae9dd5147a (patch)
treea7bb3b5f0fafddeeb00394a7ae83191267e51acd /src/testing/test_testing_peerstartup2.c
parentad25eef39dc8c15b85bd70c6585af95d7e687fd5 (diff)
downloadgnunet-ea931ffc94e1f8145c30c98da50cd5ae9dd5147a.tar.gz
gnunet-ea931ffc94e1f8145c30c98da50cd5ae9dd5147a.zip
- add GNUNET_TESTING_peer_stop_async_cancel()
Diffstat (limited to 'src/testing/test_testing_peerstartup2.c')
-rw-r--r--src/testing/test_testing_peerstartup2.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/testing/test_testing_peerstartup2.c b/src/testing/test_testing_peerstartup2.c
index cd8141b40..959651041 100644
--- a/src/testing/test_testing_peerstartup2.c
+++ b/src/testing/test_testing_peerstartup2.c
@@ -148,10 +148,9 @@ do_shutdown (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
148 GNUNET_TESTING_peer_stop_async (test_ctx->peer, 148 GNUNET_TESTING_peer_stop_async (test_ctx->peer,
149 &peer_status_cb, 149 &peer_status_cb,
150 test_ctx)); 150 test_ctx));
151
152 } 151 }
153 else 152 else
154 do_shutdown (test_ctx, tc); 153 do_shutdown2 (test_ctx, tc);
155} 154}
156 155
157 156
@@ -187,6 +186,11 @@ run (void *cls, char *const *args, const char *cfgfile,
187 if (GNUNET_OK != GNUNET_TESTING_peer_start (test_ctx->peer)) 186 if (GNUNET_OK != GNUNET_TESTING_peer_start (test_ctx->peer))
188 goto end; 187 goto end;
189 test_ctx->state = PEER_STARTED; 188 test_ctx->state = PEER_STARTED;
189 FAIL_TEST (GNUNET_OK ==
190 GNUNET_TESTING_peer_stop_async (test_ctx->peer,
191 &peer_status_cb,
192 test_ctx));
193 GNUNET_TESTING_peer_stop_async_cancel (test_ctx->peer);
190 GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS, 194 GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_SECONDS,
191 &do_shutdown, test_ctx); 195 &do_shutdown, test_ctx);
192 return; 196 return;