expose our hello to plugins
[oweals/gnunet.git] / src / fs / fs_test_lib.h
index b9bbf7480cb86153224bd4c05e65ca800d67b8ca..d25f594e3cc59e2355a294e9d6b1535d4a88fd2d 100644 (file)
@@ -4,7 +4,7 @@
 
      GNUnet is free software; you can redistribute it and/or modify
      it under the terms of the GNU General Public License as published
-     by the Free Software Foundation; either version 2, or (at your
+     by the Free Software Foundation; either version 3, or (at your
      option) any later version.
 
      GNUnet is distributed in the hope that it will be useful, but
 */
 
 /**
- * @file fs/test_fs_lib.h
+ * @file fs/fs_test_lib.h
  * @brief library routines for testing FS publishing and downloading
  *        with multiple peers; this code is limited to flat files
  *        and no keywords (those functions can be tested with
  *        single-peer setups; this is for testing routing).
  * @author Christian Grothoff
  */
-#ifndef TEST_FS_LIB_H
-#define TEST_FS_LIB_H
+#ifndef FS_TEST_LIB_H
+#define FS_TEST_LIB_H
 
 #include "gnunet_util_lib.h"
 #include "gnunet_fs_service.h"
@@ -42,6 +42,7 @@ struct GNUNET_FS_TestDaemon;
  * Start daemons for testing.
  *
  * @param sched scheduler to use
+ * @param template_cfg_file configuration template to use
  * @param timeout if this operation cannot be completed within the
  *                given period, call the continuation with an error code
  * @param total number of daemons to start
@@ -52,6 +53,7 @@ struct GNUNET_FS_TestDaemon;
  */
 void
 GNUNET_FS_TEST_daemons_start (struct GNUNET_SCHEDULER_Handle *sched,
+                             const char *template_cfg_file,
                              struct GNUNET_TIME_Relative timeout,
                              unsigned int total,
                              struct GNUNET_FS_TestDaemon **daemons,
@@ -79,6 +81,17 @@ GNUNET_FS_TEST_daemons_connect (struct GNUNET_SCHEDULER_Handle *sched,
                                void *cont_cls);
 
 
+/**
+ * Obtain peer group used for testing.
+ *
+ * @param daemons array with the daemons (must contain at least one)
+ * @return peer group
+ */
+struct GNUNET_TESTING_PeerGroup *
+GNUNET_FS_TEST_get_group (struct GNUNET_FS_TestDaemon **daemons);
+
+
+
 /**
  * Stop daemons used for testing.
  *
@@ -141,6 +154,7 @@ GNUNET_FS_TEST_publish (struct GNUNET_SCHEDULER_Handle *sched,
  *                given period, call the continuation with an error code
  * @param anonymity option for download
  * @param seed used for file validation
+ * @param uri URI of file to download (CHK/LOC only)
  * @param verbose how verbose to be in reporting
  * @param cont function to call when done
  * @param cont_cls closure for cont