diff options
Diffstat (limited to 'src/mesh/test_mesh_regex.c')
-rw-r--r-- | src/mesh/test_mesh_regex.c | 27 |
1 files changed, 2 insertions, 25 deletions
diff --git a/src/mesh/test_mesh_regex.c b/src/mesh/test_mesh_regex.c index 8e65324df..4bb0c8ddf 100644 --- a/src/mesh/test_mesh_regex.c +++ b/src/mesh/test_mesh_regex.c | |||
@@ -27,7 +27,6 @@ | |||
27 | #include "gnunet_testing_lib.h" | 27 | #include "gnunet_testing_lib.h" |
28 | #include "gnunet_mesh_service.h" | 28 | #include "gnunet_mesh_service.h" |
29 | 29 | ||
30 | #define VERBOSE GNUNET_YES | ||
31 | #define REMOVE_DIR GNUNET_YES | 30 | #define REMOVE_DIR GNUNET_YES |
32 | #define MESH_REGEX_PEERS 4 | 31 | #define MESH_REGEX_PEERS 4 |
33 | 32 | ||
@@ -159,13 +158,11 @@ shutdown_callback (void *cls, const char *emsg) | |||
159 | for (i = 0; i < MESH_REGEX_PEERS; i++) | 158 | for (i = 0; i < MESH_REGEX_PEERS; i++) |
160 | ok[i] = GNUNET_NO; | 159 | ok[i] = GNUNET_NO; |
161 | } | 160 | } |
162 | #if VERBOSE | ||
163 | else | 161 | else |
164 | { | 162 | { |
165 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 163 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
166 | "test: All peers successfully shut down!\n"); | 164 | "test: All peers successfully shut down!\n"); |
167 | } | 165 | } |
168 | #endif | ||
169 | GNUNET_CONFIGURATION_destroy (testing_cfg); | 166 | GNUNET_CONFIGURATION_destroy (testing_cfg); |
170 | } | 167 | } |
171 | 168 | ||
@@ -180,9 +177,7 @@ shutdown_callback (void *cls, const char *emsg) | |||
180 | static void | 177 | static void |
181 | shutdown_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) | 178 | shutdown_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc) |
182 | { | 179 | { |
183 | #if VERBOSE | ||
184 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "test: Ending test.\n"); | 180 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "test: Ending test.\n"); |
185 | #endif | ||
186 | shutdown_handle = GNUNET_SCHEDULER_NO_TASK; | 181 | shutdown_handle = GNUNET_SCHEDULER_NO_TASK; |
187 | GNUNET_TESTING_daemons_stop (pg, TIMEOUT, &shutdown_callback, NULL); | 182 | GNUNET_TESTING_daemons_stop (pg, TIMEOUT, &shutdown_callback, NULL); |
188 | } | 183 | } |
@@ -407,13 +402,9 @@ peergroup_ready (void *cls, const char *emsg) | |||
407 | GNUNET_TESTING_daemons_stop (pg, TIMEOUT, &shutdown_callback, NULL); | 402 | GNUNET_TESTING_daemons_stop (pg, TIMEOUT, &shutdown_callback, NULL); |
408 | return; | 403 | return; |
409 | } | 404 | } |
410 | #if VERBOSE | 405 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
411 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | 406 | "Peer Group started successfully with %u connections\n", |
412 | "test: Peer Group started successfully!\n"); | ||
413 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "test: Have %u connections\n", | ||
414 | total_connections); | 407 | total_connections); |
415 | #endif | ||
416 | |||
417 | peers_running = GNUNET_TESTING_daemons_running (pg); | 408 | peers_running = GNUNET_TESTING_daemons_running (pg); |
418 | if (0 < failed_connections) | 409 | if (0 < failed_connections) |
419 | { | 410 | { |
@@ -519,19 +510,9 @@ run (void *cls, char *const *args, const char *cfgfile, | |||
519 | testing_cfg = GNUNET_CONFIGURATION_dup (cfg); | 510 | testing_cfg = GNUNET_CONFIGURATION_dup (cfg); |
520 | 511 | ||
521 | GNUNET_log_setup ("test_mesh_regex", | 512 | GNUNET_log_setup ("test_mesh_regex", |
522 | #if VERBOSE | ||
523 | "DEBUG", | ||
524 | #else | ||
525 | "WARNING", | 513 | "WARNING", |
526 | #endif | ||
527 | NULL); | 514 | NULL); |
528 | |||
529 | #if VERBOSE | ||
530 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "test: Starting daemons.\n"); | 515 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "test: Starting daemons.\n"); |
531 | GNUNET_CONFIGURATION_set_value_string (testing_cfg, "testing_old", | ||
532 | "use_progressbars", "YES"); | ||
533 | #endif | ||
534 | |||
535 | if (GNUNET_OK != | 516 | if (GNUNET_OK != |
536 | GNUNET_CONFIGURATION_get_value_number (testing_cfg, "testing_old", | 517 | GNUNET_CONFIGURATION_get_value_number (testing_cfg, "testing_old", |
537 | "num_peers", &num_peers)) | 518 | "num_peers", &num_peers)) |
@@ -574,10 +555,6 @@ main (int argc, char *argv[]) | |||
574 | argv[0], | 555 | argv[0], |
575 | "-c", | 556 | "-c", |
576 | "test_mesh_2dtorus.conf", | 557 | "test_mesh_2dtorus.conf", |
577 | #if VERBOSE | ||
578 | "-L", | ||
579 | "DEBUG", | ||
580 | #endif | ||
581 | NULL | 558 | NULL |
582 | }; | 559 | }; |
583 | int result; | 560 | int result; |