diff options
author | Christian Grothoff <christian@grothoff.org> | 2015-05-25 20:59:29 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2015-05-25 20:59:29 +0000 |
commit | a1aee7611781a9991c31dbaa36d38c95ad5d5300 (patch) | |
tree | 76fa1711815f47f559fbdf02fffb9c5792837d26 /src/include/gnunet_testing_lib.h | |
parent | 33a7282c26b14f838ad6f1016b90b710cec5f93f (diff) | |
download | gnunet-a1aee7611781a9991c31dbaa36d38c95ad5d5300.tar.gz gnunet-a1aee7611781a9991c31dbaa36d38c95ad5d5300.zip |
-comments, doxygen, indentation, style fixes, working on test_gns_vpn
Diffstat (limited to 'src/include/gnunet_testing_lib.h')
-rw-r--r-- | src/include/gnunet_testing_lib.h | 34 |
1 files changed, 19 insertions, 15 deletions
diff --git a/src/include/gnunet_testing_lib.h b/src/include/gnunet_testing_lib.h index 4cb518dc3..04975d077 100644 --- a/src/include/gnunet_testing_lib.h +++ b/src/include/gnunet_testing_lib.h | |||
@@ -226,7 +226,8 @@ GNUNET_TESTING_release_port (struct GNUNET_TESTING_System *system, | |||
226 | * | 226 | * |
227 | * @param system system to use to coordinate resource usage | 227 | * @param system system to use to coordinate resource usage |
228 | * @param cfg template configuration to update | 228 | * @param cfg template configuration to update |
229 | * @return GNUNET_OK on success, GNUNET_SYSERR on error - the configuration will | 229 | * @return #GNUNET_OK on success, |
230 | * #GNUNET_SYSERR on error - the configuration will | ||
230 | * be incomplete and should not be used there upon | 231 | * be incomplete and should not be used there upon |
231 | */ | 232 | */ |
232 | int | 233 | int |
@@ -271,7 +272,8 @@ GNUNET_TESTING_peer_get_identity (struct GNUNET_TESTING_Peer *peer, | |||
271 | * Start the peer. | 272 | * Start the peer. |
272 | * | 273 | * |
273 | * @param peer peer to start | 274 | * @param peer peer to start |
274 | * @return GNUNET_OK on success, GNUNET_SYSERR on error (i.e. peer already running) | 275 | * @return #GNUNET_OK on success, |
276 | * #GNUNET_SYSERR on error (i.e. peer already running) | ||
275 | */ | 277 | */ |
276 | int | 278 | int |
277 | GNUNET_TESTING_peer_start (struct GNUNET_TESTING_Peer *peer); | 279 | GNUNET_TESTING_peer_start (struct GNUNET_TESTING_Peer *peer); |
@@ -283,7 +285,8 @@ GNUNET_TESTING_peer_start (struct GNUNET_TESTING_Peer *peer); | |||
283 | * GNUNET_TESTING_peer_stop_async(). | 285 | * GNUNET_TESTING_peer_stop_async(). |
284 | * | 286 | * |
285 | * @param peer peer to stop | 287 | * @param peer peer to stop |
286 | * @return GNUNET_OK on success, GNUNET_SYSERR on error (i.e. peer not running) | 288 | * @return #GNUNET_OK on success, |
289 | * #GNUNET_SYSERR on error (i.e. peer not running) | ||
287 | */ | 290 | */ |
288 | int | 291 | int |
289 | GNUNET_TESTING_peer_stop (struct GNUNET_TESTING_Peer *peer); | 292 | GNUNET_TESTING_peer_stop (struct GNUNET_TESTING_Peer *peer); |
@@ -304,7 +307,7 @@ GNUNET_TESTING_peer_destroy (struct GNUNET_TESTING_Peer *peer); | |||
304 | * Sends SIGTERM to the peer's main process | 307 | * Sends SIGTERM to the peer's main process |
305 | * | 308 | * |
306 | * @param peer the handle to the peer | 309 | * @param peer the handle to the peer |
307 | * @return GNUNET_OK if successful; GNUNET_SYSERR if the main process is NULL | 310 | * @return #GNUNET_OK if successful; #GNUNET_SYSERR if the main process is NULL |
308 | * or upon any error while sending SIGTERM | 311 | * or upon any error while sending SIGTERM |
309 | */ | 312 | */ |
310 | int | 313 | int |
@@ -315,7 +318,7 @@ GNUNET_TESTING_peer_kill (struct GNUNET_TESTING_Peer *peer); | |||
315 | * Waits for a peer to terminate. The peer's main process will also be destroyed. | 318 | * Waits for a peer to terminate. The peer's main process will also be destroyed. |
316 | * | 319 | * |
317 | * @param peer the handle to the peer | 320 | * @param peer the handle to the peer |
318 | * @return GNUNET_OK if successful; GNUNET_SYSERR if the main process is NULL | 321 | * @return #GNUNET_OK if successful; #GNUNET_SYSERR if the main process is NULL |
319 | * or upon any error while waiting | 322 | * or upon any error while waiting |
320 | */ | 323 | */ |
321 | int | 324 | int |
@@ -327,13 +330,13 @@ GNUNET_TESTING_peer_wait (struct GNUNET_TESTING_Peer *peer); | |||
327 | * | 330 | * |
328 | * @param cls the closure given to GNUNET_TESTING_peer_stop_async() | 331 | * @param cls the closure given to GNUNET_TESTING_peer_stop_async() |
329 | * @param peer the respective peer whose status is being reported | 332 | * @param peer the respective peer whose status is being reported |
330 | * @param success GNUNET_YES if the peer is stopped; GNUNET_SYSERR upon any | 333 | * @param success #GNUNET_YES if the peer is stopped; #GNUNET_SYSERR upon any |
331 | * error | 334 | * error |
332 | */ | 335 | */ |
333 | typedef void (*GNUNET_TESTING_PeerStopCallback) (void *cls, | 336 | typedef void |
334 | struct GNUNET_TESTING_Peer * | 337 | (*GNUNET_TESTING_PeerStopCallback) (void *cls, |
335 | peer, | 338 | struct GNUNET_TESTING_Peer *peer, |
336 | int success); | 339 | int success); |
337 | 340 | ||
338 | 341 | ||
339 | /** | 342 | /** |
@@ -368,15 +371,16 @@ GNUNET_TESTING_peer_stop_async_cancel (struct GNUNET_TESTING_Peer *peer); | |||
368 | 371 | ||
369 | /** | 372 | /** |
370 | * Signature of the 'main' function for a (single-peer) testcase that | 373 | * Signature of the 'main' function for a (single-peer) testcase that |
371 | * is run using 'GNUNET_TESTING_peer_run'. | 374 | * is run using #GNUNET_TESTING_peer_run(). |
372 | * | 375 | * |
373 | * @param cls closure | 376 | * @param cls closure |
374 | * @param cfg configuration of the peer that was started | 377 | * @param cfg configuration of the peer that was started |
375 | * @param peer identity of the peer that was created | 378 | * @param peer identity of the peer that was created |
376 | */ | 379 | */ |
377 | typedef void (*GNUNET_TESTING_TestMain) (void *cls, | 380 | typedef void |
378 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 381 | (*GNUNET_TESTING_TestMain) (void *cls, |
379 | struct GNUNET_TESTING_Peer *peer); | 382 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
383 | struct GNUNET_TESTING_Peer *peer); | ||
380 | 384 | ||
381 | 385 | ||
382 | /** | 386 | /** |
@@ -420,7 +424,7 @@ GNUNET_TESTING_peer_run (const char *testdir, | |||
420 | * @param cfgfilename name of the configuration file to use; | 424 | * @param cfgfilename name of the configuration file to use; |
421 | * use NULL to only run with defaults | 425 | * use NULL to only run with defaults |
422 | * @param tm main function of the testcase | 426 | * @param tm main function of the testcase |
423 | * @param tm_cls closure for 'tm' | 427 | * @param tm_cls closure for @a tm |
424 | * @return 0 on success, 1 on error | 428 | * @return 0 on success, 1 on error |
425 | */ | 429 | */ |
426 | int | 430 | int |