Go to the source code of this file.
Data Structures | |
struct | ConnectPeersState |
Struct to store information needed in callbacks. More... | |
struct | TestState |
Macros | |
#define | GNUNET_TRANSPORT_SIMPLE_TRAITS(op, prefix) op (prefix, connect_peer_state, const struct ConnectPeersState) |
Call op on all simple traits. More... | |
Typedefs | |
typedef void *(* | GNUNET_TRANSPORT_notify_connect_cb) (struct GNUNET_TESTING_Interpreter *is, const struct GNUNET_PeerIdentity *peer) |
Functions | |
struct GNUNET_TESTING_Command | GNUNET_TRANSPORT_cmd_start_peer (const char *label, const char *system_label, uint32_t no, const char *node_ip, struct GNUNET_MQ_MessageHandler *handlers, const char *cfgname, GNUNET_TRANSPORT_notify_connect_cb notify_connect, unsigned int broadcast) |
Create command. More... | |
struct GNUNET_TESTING_Command | GNUNET_TRANSPORT_cmd_stop_peer (const char *label, const char *start_label) |
Create command. More... | |
struct GNUNET_TESTING_Command | GNUNET_TRANSPORT_cmd_connect_peers (const char *label, const char *start_peer_label, const char *create_label, uint32_t num, struct GNUNET_TESTING_NetjailTopology *topology, unsigned int additional_connects, unsigned int wait_for_connect) |
Create command. More... | |
struct GNUNET_TESTING_Command | GNUNET_TRANSPORT_cmd_send_simple (const char *label, const char *start_peer_label, const char *create_label, uint32_t num, struct GNUNET_TESTING_NetjailTopology *topology) |
Create command. More... | |
struct GNUNET_TESTING_Command | GNUNET_TRANSPORT_cmd_send_simple_performance (const char *label, const char *start_peer_label, const char *create_label, uint32_t num, int size, int max_send, struct GNUNET_TESTING_NetjailTopology *topology) |
struct GNUNET_TESTING_Command | GNUNET_TRANSPORT_cmd_backchannel_check (const char *label, const char *start_peer_label, const char *create_label, uint32_t num, unsigned int node_n, unsigned int namespace_n, struct GNUNET_TESTING_NetjailTopology *topology) |
Create command. More... | |
#define GNUNET_TRANSPORT_SIMPLE_TRAITS | ( | op, | |
prefix | |||
) | op (prefix, connect_peer_state, const struct ConnectPeersState) |
Call op on all simple traits.
Definition at line 253 of file transport-testing-cmds.h.
typedef void *(* GNUNET_TRANSPORT_notify_connect_cb) (struct GNUNET_TESTING_Interpreter *is, const struct GNUNET_PeerIdentity *peer) |
Definition at line 107 of file transport-testing-cmds.h.
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_start_peer | ( | const char * | label, |
const char * | system_label, | ||
uint32_t | no, | ||
const char * | node_ip, | ||
struct GNUNET_MQ_MessageHandler * | handlers, | ||
const char * | cfgname, | ||
GNUNET_TRANSPORT_notify_connect_cb | notify_connect, | ||
unsigned int | broadcast | ||
) |
Create command.
label | name for command. |
system_label | Label of the cmd to setup a test environment. |
no | Decimal number representing the last byte of the IP address of this peer. |
node_ip | The IP address of this node. |
handlers | Handler for messages received by this peer. |
cfgname | Configuration file name for this peer. |
notify_connect | Method which will be called, when a peer connects. |
broadcast | Flag indicating, if broadcast should be switched on. |
Definition at line 444 of file transport_api_cmd_start_peer.c.
References GNUNET_TESTING_StartPeerState::ac, GNUNET_TESTING_StartPeerState::broadcast, GNUNET_TESTING_StartPeerState::cfgname, GNUNET_TESTING_StartPeerState::connected_peers_map, GNUNET_CONTAINER_multishortmap_create(), GNUNET_memcpy, GNUNET_new, GNUNET_new_array, GNUNET_NO, GNUNET_strdup, GNUNET_TESTING_command_new_ac(), handlers, GNUNET_TESTING_StartPeerState::handlers, GNUNET_TESTING_StartPeerState::no, GNUNET_TESTING_StartPeerState::node_ip, GNUNET_TESTING_StartPeerState::notify_connect, notify_connect(), start_peer_cleanup(), start_peer_run(), start_peer_traits(), and GNUNET_TESTING_StartPeerState::system_label.
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_stop_peer | ( | const char * | label, |
const char * | start_label | ||
) |
Create command.
label | name for command. |
start_label | Label of the cmd to start the peer. |
Definition at line 141 of file transport_api_cmd_stop_peer.c.
References GNUNET_new, GNUNET_TESTING_command_new, StopPeerState::label, StopPeerState::start_label, stop_peer_cleanup(), stop_peer_run(), and stop_peer_traits().
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_connect_peers | ( | const char * | label, |
const char * | start_peer_label, | ||
const char * | create_label, | ||
uint32_t | num, | ||
struct GNUNET_TESTING_NetjailTopology * | topology, | ||
unsigned int | additional_connects, | ||
unsigned int | wait_for_connect | ||
) |
Create command.
label | name for command |
start_peer_label | Label of the cmd to start a peer. |
create_label | Label of the cmd which started the test system. |
num | Number globally identifying the node. |
topology | The topology for the test setup. |
additional_connects | Number of additional connects this cmd will wait for not triggered by this cmd. |
Definition at line 264 of file transport_api_cmd_connecting_peers.c.
References ConnectPeersState::ac, ConnectPeersState::additional_connects, connect_peers_cleanup(), connect_peers_run(), connect_peers_traits(), ConnectPeersState::create_label, GNUNET_ERROR_TYPE_DEBUG, GNUNET_new, GNUNET_TESTING_command_new, GNUNET_TESTING_command_new_ac(), GNUNET_TESTING_get_additional_connects(), GNUNET_YES, LOG, ConnectPeersState::notify_connect, notify_connect(), ConnectPeersState::num, ConnectPeersState::start_peer_label, ConnectPeersState::topology, and ConnectPeersState::wait_for_connect.
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_send_simple | ( | const char * | label, |
const char * | start_peer_label, | ||
const char * | create_label, | ||
uint32_t | num, | ||
struct GNUNET_TESTING_NetjailTopology * | topology | ||
) |
Create command.
label | name for command. |
start_peer_label | Label of the cmd to start a peer. |
create_label | Label of the cmd which started the test system. |
num | Number globally identifying the node. |
topology | The topology for the test setup. |
Definition at line 141 of file transport_api_cmd_send_simple.c.
References SendSimpleState::create_label, GNUNET_new, GNUNET_TESTING_command_new, SendSimpleState::num, send_simple_cleanup(), send_simple_run(), SendSimpleState::start_peer_label, and SendSimpleState::topology.
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_send_simple_performance | ( | const char * | label, |
const char * | start_peer_label, | ||
const char * | create_label, | ||
uint32_t | num, | ||
int | size, | ||
int | max_send, | ||
struct GNUNET_TESTING_NetjailTopology * | topology | ||
) |
label | name for command. |
start_peer_label | Label of the cmd to start a peer. |
create_label | Label of the cmd which started the test system. |
num | Number globally identifying the node. |
size | The size of the test message to send. |
max_send | The number of messages to send. |
topology | The topology for the test setup. |
Definition at line 192 of file transport_api_cmd_send_simple_performance.c.
References SendSimplePerfState::ac, GNUNET_TESTING_Command::asynchronous_finish, SendSimplePerfState::create_label, GNUNET_new, GNUNET_TESTING_command_new_ac(), GNUNET_YES, GNUNET_TESTING_Command::label, SendSimplePerfState::max_send, send_simple_cleanup(), send_simple_run(), size, SendSimplePerfState::size, SendSimplePerfState::start_peer_label, and SendSimplePerfState::topology.
struct GNUNET_TESTING_Command GNUNET_TRANSPORT_cmd_backchannel_check | ( | const char * | label, |
const char * | start_peer_label, | ||
const char * | create_label, | ||
uint32_t | num, | ||
unsigned int | node_n, | ||
unsigned int | namespace_n, | ||
struct GNUNET_TESTING_NetjailTopology * | topology | ||
) |
Create command.
label | name for command. |
start_peer_label | Label of the cmd to start a peer. |
create_label | Label of the cmd to create the testing system. |
num | Number globally identifying the node. |
node_n | The number of the node in a network namespace. |
namespace_n | The number of the network namespace. |
topology | The topology for the test setup. |
Definition at line 529 of file transport_api_cmd_backchannel_check.c.
References CheckState::ac, backchannel_check_cleanup(), backchannel_check_run(), backchannel_check_traits(), CheckState::create_label, GNUNET_new, GNUNET_TESTING_command_new_ac(), CheckState::namespace_n, CheckState::node_n, CheckState::num, CheckState::start_peer_label, and CheckState::topology.