From 6b2c5a92fbc3a57c42fc9fb38c4705ecb7afb328 Mon Sep 17 00:00:00 2001 From: t3sserakt Date: Thu, 22 Jul 2021 17:03:02 +0200 Subject: - added first testcase cmd code for sending a simple testmessage --- src/include/gnunet_testbed_ng_service.h | 3 ++- src/include/gnunet_testing_ng_lib.h | 37 +++++++++++++++++++++++++++++++++ src/include/gnunet_testing_plugin.h | 4 +++- 3 files changed, 42 insertions(+), 2 deletions(-) (limited to 'src/include') diff --git a/src/include/gnunet_testbed_ng_service.h b/src/include/gnunet_testbed_ng_service.h index caaee26b6..49e9f56bc 100644 --- a/src/include/gnunet_testbed_ng_service.h +++ b/src/include/gnunet_testbed_ng_service.h @@ -232,7 +232,8 @@ GNUNET_TESTBED_cmd_netjail_start (const char *label, struct GNUNET_TESTING_Command GNUNET_TESTBED_cmd_netjail_start_testbed (const char *label, char *local_m, - char *global_n); + char *global_n, + char *plugin_name); /** diff --git a/src/include/gnunet_testing_ng_lib.h b/src/include/gnunet_testing_ng_lib.h index 8927fd4f1..994ce31f1 100644 --- a/src/include/gnunet_testing_ng_lib.h +++ b/src/include/gnunet_testing_ng_lib.h @@ -29,6 +29,8 @@ #include "gnunet_util_lib.h" #include "gnunet_testing_plugin.h" +#include "gnunet_transport_application_service.h" +#include "gnunet_testing_lib.h" /* ********************* Helper functions ********************* */ @@ -831,4 +833,39 @@ int GNUNET_TESTING_get_trait_what_am_i (const struct GNUNET_TESTING_Command *cmd, char **what_am_i); +int +GNUNET_TESTING_get_trait_application_handle (const struct + GNUNET_TESTING_Command *cmd, + struct + GNUNET_TRANSPORT_ApplicationHandle + **ah); + +int +GNUNET_TESTING_get_trait_peer_id (const struct + GNUNET_TESTING_Command *cmd, + struct GNUNET_PeerIdentity **id); + +int +GNUNET_TESTING_get_trait_connected_peers_map (const struct + GNUNET_TESTING_Command + *cmd, + struct + GNUNET_CONTAINER_MultiPeerMap ** + connected_peers_map); +int +GNUNET_TESTING_get_trait_hello_size (const struct + GNUNET_TESTING_Command + *cmd, + size_t **hello_size); + +int +GNUNET_TESTING_get_trait_hello (const struct + GNUNET_TESTING_Command + *cmd, + char **hello); + +int +GNUNET_TESTING_get_trait_test_system (const struct + GNUNET_TESTING_Command *cmd, + struct GNUNET_TESTING_System **test_system); #endif diff --git a/src/include/gnunet_testing_plugin.h b/src/include/gnunet_testing_plugin.h index 6a54cacd2..8395e2a49 100644 --- a/src/include/gnunet_testing_plugin.h +++ b/src/include/gnunet_testing_plugin.h @@ -43,7 +43,9 @@ typedef void typedef void (*GNUNET_TESTING_PLUGIN_StartTestCase) (TESTBED_CMD_HELPER_write_cb write_message, char *router_ip, - char *node_ip); + char *node_ip, + char *n, + char *m); typedef void (*GNUNET_TESTING_PLUGIN_ALL_PEERS_STARTED) (); -- cgit v1.2.3