diff options
author | Dan Winship <danw@gnome.org> | 2012-11-06 10:37:54 -0500 |
---|---|---|
committer | Dan Winship <danw@gnome.org> | 2013-12-11 10:38:22 +0100 |
commit | d834e1e5d8e41f7fa1c082a7ab1ab9ce0335daed (patch) | |
tree | fc78810f7722534d568833e0c03ec457651fdf27 /tests/chunk-test.c | |
parent | dd3e2f4d9be661a5fae96c81618fb25c438916da (diff) | |
download | libsoup-wip/server.tar.gz |
SoupServer: add exciting new APIs, deprecate musty old oneswip/server
FIXME: server-howto
Diffstat (limited to 'tests/chunk-test.c')
-rw-r--r-- | tests/chunk-test.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/tests/chunk-test.c b/tests/chunk-test.c index ce929565..050deb06 100644 --- a/tests/chunk-test.c +++ b/tests/chunk-test.c @@ -506,22 +506,19 @@ main (int argc, char **argv) { GMainLoop *loop; SoupServer *server; - guint port; - SoupURI *base_uri; + SoupURI *uri; test_init (argc, argv, NULL); - server = soup_test_server_new (TRUE); + server = soup_test_server_new (SOUP_TEST_SERVER_IN_THREAD); soup_server_add_handler (server, NULL, server_callback, NULL, NULL); - port = soup_server_get_port (server); loop = g_main_loop_new (NULL, TRUE); - base_uri = soup_uri_new ("http://127.0.0.1"); - soup_uri_set_port (base_uri, port); - do_chunk_tests (base_uri); - soup_uri_free (base_uri); + uri = soup_test_server_get_uri (server, "http", NULL); + do_chunk_tests (uri); + soup_uri_free (uri); g_main_loop_unref (loop); soup_test_server_quit_unref (server); |