aboutsummaryrefslogtreecommitdiff
path: root/src/transport/test_plugin_transport_http.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/transport/test_plugin_transport_http.c')
-rw-r--r--src/transport/test_plugin_transport_http.c28
1 files changed, 13 insertions, 15 deletions
diff --git a/src/transport/test_plugin_transport_http.c b/src/transport/test_plugin_transport_http.c
index 9095e14c5..1e9f36286 100644
--- a/src/transport/test_plugin_transport_http.c
+++ b/src/transport/test_plugin_transport_http.c
@@ -18,11 +18,9 @@
18 Boston, MA 02111-1307, USA. 18 Boston, MA 02111-1307, USA.
19*/ 19*/
20/** 20/**
21 * @file transport/test_transport_api.c 21 * @file transport/test_plugin_transport_http.c
22 * @brief testcase for transport_api.c 22 * @brief testcase for plugin_transport_http.c
23 * @author Sailor Siraj 23 * @author Matthias Wachs
24 * @author Christian Grothoff
25 * @author Nathan Evans
26 */ 24 */
27 25
28#include "platform.h" 26#include "platform.h"
@@ -38,7 +36,7 @@
38#include "plugin_transport.h" 36#include "plugin_transport.h"
39#include "transport.h" 37#include "transport.h"
40 38
41#define VERBOSE GNUNET_NO 39#define VERBOSE GNUNET_YES
42 40
43/** 41/**
44 * How long until we give up on transmitting the message? 42 * How long until we give up on transmitting the message?
@@ -223,15 +221,15 @@ run (void *cls,
223 221
224 /* load plugins... */ 222 /* load plugins... */
225 setup_plugin_environment (); 223 setup_plugin_environment ();
226 GNUNET_log (GNUNET_ERROR_TYPE_INFO, _("Loading udp transport plugin\n")); 224 GNUNET_log (GNUNET_ERROR_TYPE_INFO, _("Loading http transport plugin\n"));
227 GNUNET_asprintf (&libname, "libgnunet_plugin_transport_udp"); 225 GNUNET_asprintf (&libname, "libgnunet_plugin_transport_http");
228 226
229 api = GNUNET_PLUGIN_load (libname, &env); 227 api = GNUNET_PLUGIN_load (libname, &env);
230 GNUNET_free (libname); 228 GNUNET_free (libname);
231 if (api == NULL) 229 if (api == NULL)
232 { 230 {
233 GNUNET_log (GNUNET_ERROR_TYPE_ERROR, 231 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
234 _("Failed to load transport plugin for udp\n")); 232 _("Failed to load transport plugin for http\n"));
235 /* FIXME: set some error code for main */ 233 /* FIXME: set some error code for main */
236 return; 234 return;
237 } 235 }
@@ -254,9 +252,9 @@ main (int argc, char *const *argv)
254 }; 252 };
255 int ret; 253 int ret;
256 char *const argv_prog[] = { 254 char *const argv_prog[] = {
257 "test_plugin_transport", 255 "test-gnunetd-plugin-transport_http",
258 "-c", 256 "-c",
259 "test_plugin_transport_data_udp.conf", 257 "test_plugin_transport_data_http.conf",
260 "-L", 258 "-L",
261#if VERBOSE 259#if VERBOSE
262 "DEBUG", 260 "DEBUG",
@@ -265,7 +263,7 @@ main (int argc, char *const *argv)
265#endif 263#endif
266 NULL 264 NULL
267 }; 265 };
268 GNUNET_log_setup ("test-plugin-transport", 266 GNUNET_log_setup ("test-gnunetd-plugin-transport_http",
269#if VERBOSE 267#if VERBOSE
270 "DEBUG", 268 "DEBUG",
271#else 269#else
@@ -276,12 +274,12 @@ main (int argc, char *const *argv)
276 ret = (GNUNET_OK == 274 ret = (GNUNET_OK ==
277 GNUNET_PROGRAM_run (5, 275 GNUNET_PROGRAM_run (5,
278 argv_prog, 276 argv_prog,
279 "test-plugin-transport", 277 "test-plugin-transport_http",
280 "testcase", options, &run, NULL)) ? ok : 1; 278 "testcase", options, &run, NULL)) ? ok : 1;
281 GNUNET_DISK_directory_remove ("/tmp/test-gnunetd-plugin-transport"); 279 GNUNET_DISK_directory_remove ("/tmp/test-gnunetd-plugin-transport_http");
282 /* FIXME: return correct value */ 280 /* FIXME: return correct value */
283 /* return ret; */ 281 /* return ret; */
284 return GNUNET_NO; 282 return GNUNET_NO;
285} 283}
286 284
287/* end of test_plugin_transport_udp.c */ 285/* end of test_plugin_transport_http.c */