38#define LOG(kind, ...) GNUNET_log (kind, __VA_ARGS__)
91 "Sending simple test message with mq %p\n",
97 test->
num = htonl (sss->
num);
100 1000 -
sizeof(*test));
124 &connected_peers_map);
140 const char *start_peer_label,
141 const char *create_label,
struct GNUNET_MQ_Handle * mq
struct GNUNET_MQ_Envelope * env
static struct GNUNET_TESTING_Interpreter * is
struct GNUNET_HashCode key
The key used in the DHT.
static char * value
Value of the record to add/remove.
const struct GNUNET_TESTING_Command * GNUNET_TESTING_interpreter_lookup_command(struct GNUNET_TESTING_Interpreter *is, const char *label)
Lookup command by label.
#define GNUNET_TESTING_command_new(cls, label, run, cleanup, traits)
Create a new command.
enum GNUNET_GenericReturnValue GNUNET_TESTING_TESTBED_get_trait_test_system(const struct GNUNET_TESTING_Command *cmd, struct GNUNET_TESTBED_System **ret)
enum GNUNET_GenericReturnValue GNUNET_TRANSPORT_TESTING_get_trait_connected_peers_map(const struct GNUNET_TESTING_Command *cmd, const struct GNUNET_CONTAINER_MultiShortmap **ret)
int GNUNET_CONTAINER_multishortmap_iterate(struct GNUNET_CONTAINER_MultiShortmap *map, GNUNET_CONTAINER_ShortmapIterator it, void *it_cls)
Iterate over all entries in the map.
@ GNUNET_ERROR_TYPE_DEBUG
#define GNUNET_new(type)
Allocate a struct or union of the given type.
#define GNUNET_free(ptr)
Wrapper around free.
void GNUNET_MQ_send(struct GNUNET_MQ_Handle *mq, struct GNUNET_MQ_Envelope *ev)
Send a message with the given message queue.
#define GNUNET_MQ_msg_extra(mvar, esize, type)
Allocate an envelope, with extra space allocated after the space needed by the message struct.
Internal representation of the hash map.
Handle to a message queue.
Handle for a system on which GNUnet peers are executed; a system is used for reserving unique paths a...
A command to be run by the interpreter.
struct GNUNET_TESTING_CommandLabel label
Label for the command.
Global state of the interpreter, used by a command to access information about other commands.
uint32_t num
Monotonically increasing counter throughout the test.
Struct to hold information for callbacks.
const char * create_label
Label of the cmd which started the test system.
const char * start_peer_label
Label of the cmd to start a peer.
uint32_t num
Number globally identifying the node.
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_send_simple(const char *label, const char *start_peer_label, const char *create_label, uint32_t num)
Create command.
static void send_simple_run(void *cls, struct GNUNET_TESTING_Interpreter *is)
The run method of this cmd will send a simple message to the connected peers.
static void send_simple_cleanup(void *cls)
The cleanup function of this cmd frees resources the cmd allocated.
#define LOG(kind,...)
Generic logging shortcut.
static int send_simple_cb(void *cls, const struct GNUNET_ShortHashCode *key, void *value)
#define GNUNET_TRANSPORT_TESTING_SIMPLE_MTYPE
Message type used by GNUNET_TRANSPORT_TESTING_simple_send().