diff options
author | grothoff <grothoff@140774ce-b5e7-0310-ab8b-a85725594a96> | 2011-07-04 09:02:34 +0000 |
---|---|---|
committer | grothoff <grothoff@140774ce-b5e7-0310-ab8b-a85725594a96> | 2011-07-04 09:02:34 +0000 |
commit | 35e7470f45f64b860790c93a356c2b0c0ac53d83 (patch) | |
tree | 7ca5af0c5c95215b14398379e0069414534c4dda /src/topology | |
parent | 291074fd46436adab715be99fa8f06016613ef7b (diff) |
stuff
git-svn-id: https://gnunet.org/svn/gnunet@15833 140774ce-b5e7-0310-ab8b-a85725594a96
Diffstat (limited to 'src/topology')
-rw-r--r-- | src/topology/test_gnunet_daemon_topology.c | 23 | ||||
-rw-r--r-- | src/topology/test_gnunet_daemon_topology_data.conf | 5 |
2 files changed, 17 insertions, 11 deletions
diff --git a/src/topology/test_gnunet_daemon_topology.c b/src/topology/test_gnunet_daemon_topology.c index 5c54e0ee31..85f328fe52 100644 --- a/src/topology/test_gnunet_daemon_topology.c +++ b/src/topology/test_gnunet_daemon_topology.c @@ -51,8 +51,9 @@ static struct GNUNET_TESTING_Daemon *last; /** * Check whether peers successfully shut down. */ -void shutdown_callback (void *cls, - const char *emsg) +static void +shutdown_callback (void *cls, + const char *emsg) { if (emsg != NULL) { @@ -72,6 +73,7 @@ void shutdown_callback (void *cls, } } + static void clean_up_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) @@ -112,11 +114,12 @@ notify_connect_complete(void *cls, } -static void my_cb(void *cls, - const struct GNUNET_PeerIdentity *id, - const struct GNUNET_CONFIGURATION_Handle *cfg, - struct GNUNET_TESTING_Daemon *d, - const char *emsg) +static +void my_cb(void *cls, + const struct GNUNET_PeerIdentity *id, + const struct GNUNET_CONFIGURATION_Handle *cfg, + struct GNUNET_TESTING_Daemon *d, + const char *emsg) { GNUNET_assert (id != NULL); peers_left--; @@ -164,10 +167,12 @@ run (void *cls, GNUNET_assert (pg != NULL); } + static int check () { - char *const argv[] = { "test-testing", + char *const argv[] = { + "test-gnunet-daemon-topology", "-c", "test_gnunet_daemon_topology_data.conf", #if VERBOSE @@ -184,6 +189,7 @@ check () return ok; } + int main (int argc, char *argv[]) { @@ -197,7 +203,6 @@ main (int argc, char *argv[]) #endif NULL); ret = check (); - sleep (1); /* FIXME: needed? */ GNUNET_DISK_directory_remove ("/tmp/test-gnunet-topology"); return ret; } diff --git a/src/topology/test_gnunet_daemon_topology_data.conf b/src/topology/test_gnunet_daemon_topology_data.conf index a2340570b8..1575b25248 100644 --- a/src/topology/test_gnunet_daemon_topology_data.conf +++ b/src/topology/test_gnunet_daemon_topology_data.conf @@ -7,7 +7,7 @@ PORT = 2664 [transport] PORT = 2665 PLUGINS = tcp -# DEBUG = YES +#DEBUG = YES #PREFIX = xterm -e xterm -T transport -e gdb -x cmd --args #PREFIX = valgrind --tool=memcheck --log-file=logs%p @@ -30,13 +30,14 @@ ALLOW_NAT = NO INTERNAL_ADDRESS = 127.0.0.1 EXTERNAL_ADDRESS = 127.0.0.1 USE_LOCALADDR = NO +USE_HOSTNAME = NO [peerinfo] PORT = 2669 [core] PORT = 2670 -# DEBUG = YES +#DEBUG = YES [topology] # DEBUG = YES |