int main(int argc, char** argv) { SoupServer* server; SoupURI* soup_uri; gtk_test_init(&argc, &argv, NULL); /* Hopefully make test independent of the path it's called from. */ testutils_relative_chdir("Source/WebKit/gtk/tests/resources/test.html", argv[0]); server = soup_server_new(SOUP_SERVER_PORT, 0, NULL); soup_server_run_async(server); soup_server_add_handler(server, NULL, server_callback, NULL, NULL); soup_uri = soup_uri_new("http://127.0.0.1/"); soup_uri_set_port(soup_uri, soup_server_get_port(server)); base_uri = soup_uri_to_string(soup_uri, FALSE); soup_uri_free(soup_uri); g_test_bug_base("https://bugs.webkit.org/"); g_test_add_func("/webkit/webview/icon-uri", test_webkit_web_view_icon_uri); g_test_add_func("/webkit/webview/adjustments", test_webkit_web_view_adjustments); g_test_add_func("/webkit/webview/destroy", test_webkit_web_view_destroy); g_test_add_func("/webkit/webview/grab_focus", test_webkit_web_view_grab_focus); g_test_add_func("/webkit/webview/window-features", test_webkit_web_view_window_features); g_test_add_func("/webkit/webview/webview-in-offscreen-window-does-not-crash", test_webkit_web_view_in_offscreen_window_does_not_crash); g_test_add_func("/webkit/webview/webview-does-not-steal-focus", test_webkit_web_view_does_not_steal_focus); g_test_add_data_func("/webkit/webview/fullscreen", GINT_TO_POINTER(FALSE), test_webkit_web_view_fullscreen); g_test_add_data_func("/webkit/webview/fullscreen-blocked", GINT_TO_POINTER(TRUE), test_webkit_web_view_fullscreen); g_test_add_func("/webkit/webview/file-chooser", test_webkit_web_view_file_chooser); return g_test_run (); }
int main(int argc, char **argv) { gtk_test_init(&argc, &argv, NULL); /* This hopefully makes the test independent of the path it's called from. */ testutils_relative_chdir("Source/WebKit/gtk/tests/resources/test.html", argv[0]); SoupServer *server = soup_server_new(SOUP_SERVER_PORT, 0, NULL); soup_server_run_async(server); soup_server_add_handler(server, NULL, serverCallback, NULL, NULL); SoupURI *soupURI = soup_uri_new("http://127.0.0.1/"); soup_uri_set_port(soupURI, soup_server_get_port(server)); baseURI = soup_uri_to_string(soupURI, FALSE); soup_uri_free(soupURI); g_test_bug_base("https://bugs.webkit.org/"); g_test_add_func("/webkit/favicondatabase/set-path", testWebKitFaviconDatabaseSetPath); // These two tests will trigger an ASSERTION on debug builds due // to http://webkit.org/b/67582. Remove the guards once the bug is fixed. #ifdef NDEBUG g_test_add_func("/webkit/favicondatabase/get-favicon", testWebKitFaviconDatabaseGetFavicon); g_test_add_func("/webkit/favicondatabase/get-favicon-uri", testWebKitFaviconDatabaseGetFaviconURI); #endif g_test_add_func("/webkit/favicondatabase/remove-all", testWebKitFaviconDatabaseRemoveAll); g_test_add_func("/webkit/favicondatabase/close-db", testWebKitFaviconDatabaseCloseDatabase); return g_test_run(); }
int main(int argc, char** argv) { SoupServer* server; SoupURI* soup_uri; g_thread_init(NULL); gtk_test_init(&argc, &argv, NULL); /* Hopefully make test independent of the path it's called from. */ testutils_relative_chdir("WebKit/gtk/tests/resources/test.html", argv[0]); server = soup_server_new(SOUP_SERVER_PORT, 0, NULL); soup_server_run_async(server); soup_server_add_handler(server, NULL, server_callback, NULL, NULL); soup_uri = soup_uri_new("http://127.0.0.1/"); soup_uri_set_port(soup_uri, soup_server_get_port(server)); base_uri = soup_uri_to_string(soup_uri, FALSE); soup_uri_free(soup_uri); g_test_bug_base("https://bugs.webkit.org/"); g_test_add_func("/webkit/webview/icon-uri", test_webkit_web_view_icon_uri); g_test_add_func("/webkit/webview/adjustments", test_webkit_web_view_adjustments); g_test_add_func("/webkit/webview/destroy", test_webkit_web_view_destroy); g_test_add_func("/webkit/webview/grab_focus", test_webkit_web_view_grab_focus); g_test_add_func("/webkit/webview/window-features", test_webkit_web_view_window_features); return g_test_run (); }