diff options
author | t3sserakt <t3ss@posteo.de> | 2021-11-29 13:24:29 +0100 |
---|---|---|
committer | t3sserakt <t3ss@posteo.de> | 2021-11-29 13:24:29 +0100 |
commit | 297ee1c85e3b8a1745193c854df2dec1126b7b99 (patch) | |
tree | 862872c1f89059dc9a43d21111eba4c932caf15a /src/transport/transport-testing-cmds.h | |
parent | fdb9fc3b6f1333a05e093ed1a8aee63d6308ced1 (diff) | |
download | gnunet-297ee1c85e3b8a1745193c854df2dec1126b7b99.tar.gz gnunet-297ee1c85e3b8a1745193c854df2dec1126b7b99.zip |
- added number of unintentional connects to connect cmd, fixed bugs in tcp communicator and tng service, added method to get a cmd not restricted to future or past cmds
Diffstat (limited to 'src/transport/transport-testing-cmds.h')
-rw-r--r-- | src/transport/transport-testing-cmds.h | 41 |
1 files changed, 34 insertions, 7 deletions
diff --git a/src/transport/transport-testing-cmds.h b/src/transport/transport-testing-cmds.h index d2e49c0d3..d64279aeb 100644 --- a/src/transport/transport-testing-cmds.h +++ b/src/transport/transport-testing-cmds.h | |||
@@ -82,6 +82,21 @@ struct ConnectPeersState | |||
82 | * Number of connections. | 82 | * Number of connections. |
83 | */ | 83 | */ |
84 | unsigned int con_num; | 84 | unsigned int con_num; |
85 | |||
86 | /** | ||
87 | * Number of additional connects this cmd will wait for not triggered by this cmd. | ||
88 | */ | ||
89 | unsigned int additional_connects; | ||
90 | |||
91 | /** | ||
92 | * Number of connections we already have a notification for. | ||
93 | */ | ||
94 | unsigned int con_num_notified; | ||
95 | |||
96 | /** | ||
97 | * Number of additional connects this cmd will wait for not triggered by this cmd we already have a notification for. | ||
98 | */ | ||
99 | unsigned int additional_connects_notified; | ||
85 | }; | 100 | }; |
86 | 101 | ||
87 | struct StartPeerState | 102 | struct StartPeerState |
@@ -227,13 +242,25 @@ GNUNET_TRANSPORT_cmd_stop_peer (const char *label, | |||
227 | const char *start_label); | 242 | const char *start_label); |
228 | 243 | ||
229 | 244 | ||
245 | /** | ||
246 | * Create command | ||
247 | * | ||
248 | * @param label name for command | ||
249 | * @param start_peer_label Label of the cmd to start a peer. | ||
250 | * @param create_peer_label Label of the cmd which started the test system. | ||
251 | * @param num Number globally identifying the node. | ||
252 | * @param The topology for the test setup. | ||
253 | * @param additional_connects Number of additional connects this cmd will wait for not triggered by this cmd. | ||
254 | * @return command. | ||
255 | */ | ||
230 | struct GNUNET_TESTING_Command | 256 | struct GNUNET_TESTING_Command |
231 | GNUNET_TRANSPORT_cmd_connect_peers (const char *label, | 257 | GNUNET_TRANSPORT_cmd_connect_peers ( |
232 | const char *start_peer_label, | 258 | const char *label, |
233 | const char *create_label, | 259 | const char *start_peer_label, |
234 | uint32_t num, | 260 | const char *create_label, |
235 | struct GNUNET_TESTING_NetjailTopology * | 261 | uint32_t num, |
236 | topology); | 262 | struct GNUNET_TESTING_NetjailTopology *topology, |
263 | unsigned int additional_connects); | ||
237 | 264 | ||
238 | 265 | ||
239 | /** | 266 | /** |
@@ -241,7 +268,7 @@ GNUNET_TRANSPORT_cmd_connect_peers (const char *label, | |||
241 | * | 268 | * |
242 | * @param label name for command. | 269 | * @param label name for command. |
243 | * @param start_peer_label Label of the cmd to start a peer. | 270 | * @param start_peer_label Label of the cmd to start a peer. |
244 | * @param start_peer_label Label of the cmd which started the test system. | 271 | * @param create_peer_label Label of the cmd which started the test system. |
245 | * @param num Number globally identifying the node. | 272 | * @param num Number globally identifying the node. |
246 | * @param The topology for the test setup. | 273 | * @param The topology for the test setup. |
247 | * @return command. | 274 | * @return command. |