diff options
Diffstat (limited to 'src/cadet/cadet_test_lib.h')
-rw-r--r-- | src/cadet/cadet_test_lib.h | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/src/cadet/cadet_test_lib.h b/src/cadet/cadet_test_lib.h index 464977d42..4b3a6b18d 100644 --- a/src/cadet/cadet_test_lib.h +++ b/src/cadet/cadet_test_lib.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2012 GNUnet e.V. | 3 | Copyright (C) 2012,2017 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software; you can redistribute it and/or modify | 5 | GNUnet is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published | 6 | it under the terms of the GNU General Public License as published |
@@ -49,41 +49,41 @@ struct GNUNET_CADET_TEST_Context; | |||
49 | * @param ctx Argument to give to GNUNET_CADET_TEST_cleanup on test end. | 49 | * @param ctx Argument to give to GNUNET_CADET_TEST_cleanup on test end. |
50 | * @param num_peers Number of peers that are running. | 50 | * @param num_peers Number of peers that are running. |
51 | * @param peers Array of peers. | 51 | * @param peers Array of peers. |
52 | * @param cadetes Handle to each of the CADETs of the peers. | 52 | * @param cadets Handle to each of the CADETs of the peers. |
53 | */ | 53 | */ |
54 | typedef void (*GNUNET_CADET_TEST_AppMain) (void *cls, | 54 | typedef void (*GNUNET_CADET_TEST_AppMain) (void *cls, |
55 | struct GNUNET_CADET_TEST_Context *ctx, | 55 | struct GNUNET_CADET_TEST_Context *ctx, |
56 | unsigned int num_peers, | 56 | unsigned int num_peers, |
57 | struct GNUNET_TESTBED_Peer **peers, | 57 | struct GNUNET_TESTBED_Peer **peers, |
58 | struct GNUNET_CADET_Handle **cadetes); | 58 | struct GNUNET_CADET_Handle **cadets); |
59 | 59 | ||
60 | 60 | ||
61 | /** | 61 | /** |
62 | * Run a test using the given name, configuration file and number of | 62 | * Run a test using the given name, configuration file and number of peers. |
63 | * peers. | 63 | * All cadet callbacks will receive the peer number (long) as the closure. |
64 | * All cadet callbacks will receive the peer number as the closure. | ||
65 | * | 64 | * |
66 | * @param testname Name of the test (for logging). | 65 | * @param testname Name of the test (for logging). |
67 | * @param cfgname Name of the configuration file. | 66 | * @param cfgfile Name of the configuration file. |
68 | * @param num_peers Number of peers to start. | 67 | * @param num_peers Number of peers to start. |
69 | * @param tmain Main function to run once the testbed is ready. | 68 | * @param tmain Main function to run once the testbed is ready. |
70 | * @param tmain_cls Closure for 'tmain'. | 69 | * @param tmain_cls Closure for @a tmain. |
71 | * @param new_channel Handler for incoming tunnels. | 70 | * @param connects Handler for incoming channels. |
72 | * @param cleaner Cleaner for destroyed incoming tunnels. | 71 | * @param window_changes Handler for the window size change notification. |
72 | * @param disconnects Cleaner for destroyed incoming channels. | ||
73 | * @param handlers Message handlers. | 73 | * @param handlers Message handlers. |
74 | * @param ports Ports the peers offer, NULL-terminated. | 74 | * @param ports Ports the peers offer, NULL-terminated. |
75 | */ | 75 | */ |
76 | void | 76 | void |
77 | GNUNET_CADET_TEST_run (const char *testname, | 77 | GNUNET_CADET_TEST_ruN (const char *testname, |
78 | const char *cfgname, | 78 | const char *cfgfile, |
79 | unsigned int num_peers, | 79 | unsigned int num_peers, |
80 | GNUNET_CADET_TEST_AppMain tmain, | 80 | GNUNET_CADET_TEST_AppMain tmain, |
81 | void *tmain_cls, | 81 | void *tmain_cls, |
82 | GNUNET_CADET_InboundChannelNotificationHandler new_channel, | 82 | GNUNET_CADET_ConnectEventHandler connects, |
83 | GNUNET_CADET_ChannelEndHandler cleaner, | 83 | GNUNET_CADET_WindowSizeEventHandler window_changes, |
84 | struct GNUNET_CADET_MessageHandler* handlers, | 84 | GNUNET_CADET_DisconnectEventHandler disconnects, |
85 | const struct GNUNET_HashCode **ports); | 85 | struct GNUNET_MQ_MessageHandler *handlers, |
86 | 86 | const struct GNUNET_HashCode **ports); | |
87 | 87 | ||
88 | /** | 88 | /** |
89 | * Clean up the testbed. | 89 | * Clean up the testbed. |