aboutsummaryrefslogtreecommitdiff
path: root/src/testbed/test_testbed_api_3peers_3controllers.c
diff options
context:
space:
mode:
authorSree Harsha Totakura <totakura@in.tum.de>2012-11-22 17:03:48 +0000
committerSree Harsha Totakura <totakura@in.tum.de>2012-11-22 17:03:48 +0000
commit3238f6daafe108e9faaa56df8bc4c10ff8af56c2 (patch)
tree7748e9a4e7dda2282ab74de8bbdddb88c5ed2bfe /src/testbed/test_testbed_api_3peers_3controllers.c
parentc2d88b4c711713ee4d5511cb30142aa4c7738548 (diff)
downloadgnunet-3238f6daafe108e9faaa56df8bc4c10ff8af56c2.tar.gz
gnunet-3238f6daafe108e9faaa56df8bc4c10ff8af56c2.zip
topology loading from file
Diffstat (limited to 'src/testbed/test_testbed_api_3peers_3controllers.c')
-rw-r--r--src/testbed/test_testbed_api_3peers_3controllers.c23
1 files changed, 18 insertions, 5 deletions
diff --git a/src/testbed/test_testbed_api_3peers_3controllers.c b/src/testbed/test_testbed_api_3peers_3controllers.c
index 48c212401..3e75469ff 100644
--- a/src/testbed/test_testbed_api_3peers_3controllers.c
+++ b/src/testbed/test_testbed_api_3peers_3controllers.c
@@ -232,7 +232,12 @@ enum Stage
232 /** 232 /**
233 * Final success stage 233 * Final success stage
234 */ 234 */
235 SUCCESS 235 SUCCESS,
236
237 /**
238 * Optional stage for marking test to be skipped
239 */
240 SKIP
236}; 241};
237 242
238/** 243/**
@@ -874,8 +879,8 @@ run (void *cls, char *const *args, const char *cfgfile,
874 (void) PRINTF ("%s", 879 (void) PRINTF ("%s",
875 "Unable to run the test as this system is not configured " 880 "Unable to run the test as this system is not configured "
876 "to use password less SSH logins to localhost.\n" 881 "to use password less SSH logins to localhost.\n"
877 "Marking test as successful\n"); 882 "Skipping test\n");
878 result = SUCCESS; 883 result = SKIP;
879 return; 884 return;
880 } 885 }
881 cfg = GNUNET_CONFIGURATION_dup (config); 886 cfg = GNUNET_CONFIGURATION_dup (config);
@@ -908,9 +913,17 @@ main (int argc, char **argv)
908 GNUNET_PROGRAM_run ((sizeof (argv2) / sizeof (char *)) - 1, argv2, 913 GNUNET_PROGRAM_run ((sizeof (argv2) / sizeof (char *)) - 1, argv2,
909 "test_testbed_api_3peers_3controllers", "nohelp", 914 "test_testbed_api_3peers_3controllers", "nohelp",
910 options, &run, NULL); 915 options, &run, NULL);
911 if ((GNUNET_OK != ret) || (SUCCESS != result)) 916 if (GNUNET_OK != ret)
917 return 1;
918 switch (result)
919 {
920 case SUCCESS:
921 return 0;
922 case SKIP:
923 return 77; /* Mark test as skipped */
924 default:
912 return 1; 925 return 1;
913 return 0; 926 }
914} 927}
915 928
916/* end of test_testbed_api_3peers_3controllers.c */ 929/* end of test_testbed_api_3peers_3controllers.c */