2 This file is part of GNUnet.
3 (C) 2006, 2009 Christian Grothoff (and other contributing authors)
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
7 by the Free Software Foundation; either version 2, or (at your
8 option) any later version.
10 GNUnet is distributed in the hope that it will be useful, but
11 WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with GNUnet; see the file COPYING. If not, write to the
17 Free Software Foundation, Inc., 59 Temple Place - Suite 330,
18 Boston, MA 02111-1307, USA.
22 * @file transport_testing.h
23 * @brief testing lib for transport service
25 * @author Matthias Wachs
29 #include "gnunet_common.h"
30 #include "gnunet_hello_lib.h"
31 #include "gnunet_getopt_lib.h"
32 #include "gnunet_os_lib.h"
33 #include "gnunet_program_lib.h"
34 #include "gnunet_transport_service.h"
35 #include "transport.h"
40 struct GNUNET_CONFIGURATION_Handle *cfg;
41 struct GNUNET_TRANSPORT_Handle *th;
42 struct GNUNET_PeerIdentity id;
43 struct GNUNET_OS_Process *arm_proc;
45 GNUNET_TRANSPORT_ReceiveCallback rec;
46 GNUNET_TRANSPORT_NotifyConnect nc;
47 GNUNET_TRANSPORT_NotifyDisconnect nd;
53 typedef void (*GNUNET_TRANSPORT_TESTING_connect_cb) (struct PeerContext * p1, struct PeerContext * p2, void *cls);
56 GNUNET_TRANSPORT_TESTING_start_peer (const char * cfgname,
57 GNUNET_TRANSPORT_ReceiveCallback rec,
58 GNUNET_TRANSPORT_NotifyConnect nc,
59 GNUNET_TRANSPORT_NotifyDisconnect nd,
63 GNUNET_TRANSPORT_TESTING_stop_peer (struct PeerContext * pc);
66 GNUNET_TRANSPORT_TESTING_connect_peers (struct PeerContext * p1,
67 struct PeerContext * p2,
68 GNUNET_TRANSPORT_TESTING_connect_cb cb,
71 /* end of transport_testing.h */