Changeset 230401 in webkit
- Timestamp:
- Apr 9, 2018 3:53:30 AM (6 years ago)
- Location:
- releases/WebKitGTK/webkit-2.20
- Files:
-
- 17 edited
Legend:
- Unmodified
- Added
- Removed
-
releases/WebKitGTK/webkit-2.20/Source/WebKit/ChangeLog
r230395 r230401 1 2018-03-07 Carlos Garcia Campos <cgarcia@igalia.com> 2 3 [GTK][WPE] Leak checker is not working in WebKitGLib web process tests 4 https://bugs.webkit.org/show_bug.cgi?id=183404 5 6 Reviewed by Michael Catanzaro. 7 8 Add private helper for testing to do a garbage collection when the page is closing. 9 10 * WebProcess/InjectedBundle/API/glib/WebKitWebExtension.cpp: 11 (webkitWebExtensionSetGarbageCollectOnPageDestroy): 12 * WebProcess/InjectedBundle/API/glib/WebKitWebExtensionPrivate.h: 13 * WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMClientRectList.h: Fix annotation of 14 webkit_dom_client_rect_list_item(), it should be transfer full. 15 1 16 2018-03-02 Brian Burg <bburg@apple.com> 2 17 -
releases/WebKitGTK/webkit-2.20/Source/WebKit/WebProcess/InjectedBundle/API/glib/WebKitWebExtension.cpp
r218487 r230401 27 27 #include "WebKitWebPagePrivate.h" 28 28 #include "WebProcess.h" 29 #include <WebCore/GCController.h> 29 30 #include <wtf/HashMap.h> 30 31 #include <wtf/glib/GRefPtr.h> … … 119 120 struct _WebKitWebExtensionPrivate { 120 121 WebPageMap pages; 122 #if ENABLE(DEVELOPER_MODE) 123 bool garbageCollectOnPageDestroy; 124 #endif 121 125 }; 122 126 … … 163 167 { 164 168 m_extension->priv->pages.remove(&page); 169 #if ENABLE(DEVELOPER_MODE) 170 if (m_extension->priv->garbageCollectOnPageDestroy) 171 WebCore::GCController::singleton().garbageCollectNow(); 172 #endif 165 173 } 166 174 … … 193 201 } 194 202 203 void webkitWebExtensionSetGarbageCollectOnPageDestroy(WebKitWebExtension* extension) 204 { 205 #if ENABLE(DEVELOPER_MODE) 206 extension->priv->garbageCollectOnPageDestroy = true; 207 #endif 208 } 209 195 210 /** 196 211 * webkit_web_extension_get_page: -
releases/WebKitGTK/webkit-2.20/Source/WebKit/WebProcess/InjectedBundle/API/glib/WebKitWebExtensionPrivate.h
r218487 r230401 18 18 */ 19 19 20 #ifndef WebKitWebExtensionPrivate_h 21 #define WebKitWebExtensionPrivate_h 20 #pragma once 22 21 23 22 #include "InjectedBundle.h" … … 25 24 26 25 WebKitWebExtension* webkitWebExtensionCreate(WebKit::InjectedBundle*); 27 28 #endif // WebKitWebExtensionPrivate_h 26 void webkitWebExtensionSetGarbageCollectOnPageDestroy(WebKitWebExtension*); -
releases/WebKitGTK/webkit-2.20/Source/WebKit/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMClientRectList.h
r214215 r230401 69 69 * Returns the #WebKitDOMClientRect object that @self contains at @index. 70 70 * 71 * Returns: (transfer none): A #WebKitDOMClientRect71 * Returns: (transfer full): A #WebKitDOMClientRect 72 72 * 73 73 * Since: 2.18 -
releases/WebKitGTK/webkit-2.20/Tools/ChangeLog
r229524 r230401 1 2018-03-07 Carlos Garcia Campos <cgarcia@igalia.com> 2 3 [GTK][WPE] Leak checker is not working in WebKitGLib web process tests 4 https://bugs.webkit.org/show_bug.cgi?id=183404 5 6 Reviewed by Michael Catanzaro. 7 8 This might have regressed when we started to use the JSC garbage collector timers. The thing is that we expect 9 that the WebProcessTester object that we expose to JavaScript is released when the web frame is destroyed, but 10 that's no longer the case. On window object cleared a GC is scheduled, but JSC timers do the actual garbage 11 collection later. In the case of tests that never happens because the web process finishes quickly after the 12 test. We need to force a garbage collection at some point when the web page is destroyed. We can't use the 13 WebKitWebPage destroy signal, since we are also checking that WebKitWebPage isn't leaked. The 14 API::InjectedBundle::Client::willDestroyPage() always happen when the page is closed, even if WebKitWebPage is 15 still alive, so we can force the GC at that point. The only problem is that the frame is detached right after 16 that point, so we can't check WebKitFrame leaks. The only frame in the tests is the main one, so we can assume 17 that if WebKitWebPage is released, the frame is too. 18 19 * TestWebKitAPI/Tests/WebKitGLib/FrameTest.cpp: 20 (WebKitFrameTest::testMainFrame): Stop checking we don't leak WebKitFrame. 21 (WebKitFrameTest::testURI): Ditto. 22 (WebKitFrameTest::testJavaScriptContext): Ditto. 23 * TestWebKitAPI/Tests/WebKitGLib/TestFrame.cpp: 24 (testWebKitFrameMainFrame): Use new WebViewTest::runWebProcessTest() API. 25 (testWebKitFrameURI): Ditto. 26 (testWebKitFrameJavaScriptContext): Ditto. 27 (webkitFrameTestRun): Deleted. 28 * TestWebKitAPI/Tests/WebKitGLib/WebProcessTest.cpp: 29 (runTest): We no longer need the special case for dom-cache test. 30 (windowObjectClearedCallback): Only expose test runner object to JavaScript when loading tests. 31 (webkit_web_extension_initialize): Call webkitWebExtensionSetGarbageCollectOnPageDestroy() to ensure a garbage 32 collection is performed when the page is closing. 33 * TestWebKitAPI/Tests/WebKitGtk/DOMClientRectTest.cpp: 34 (WebKitDOMClientRectTest::testDivClientRectsPositionAndLength): Fix memory leak, 35 webkit_dom_client_rect_list_item() returns a full reference. 36 * TestWebKitAPI/Tests/WebKitGtk/TestAutocleanups.cpp: 37 (testWebProcessAutocleanups):Use new WebViewTest::runWebProcessTest() API. 38 * TestWebKitAPI/Tests/WebKitGtk/TestDOMClientRect.cpp: 39 (testWebKitDOMClientRectDivBoundingClientRectPosition): Use new WebViewTest::runWebProcessTest() API. 40 (testWebKitDOMClientRectDivClientRectsPositionAndLength): Use new WebViewTest::runWebProcessTest() API. 41 (prepareDOMForClientRectPositionTests): Deleted. 42 * TestWebKitAPI/Tests/WebKitGtk/TestDOMNode.cpp: 43 (testWebKitDOMNodeHierarchyNavigation): Use new WebViewTest::runWebProcessTest() API. 44 (testWebKitDOMNodeInsertion): Ditto. 45 (testWebKitDOMNodeTagNamesNodeList): Ditto. 46 (testWebKitDOMNodeTagNamesHTMLCollection): Ditto. 47 (testWebKitDOMObjectCache): We no longer need to run the test several times, since runWebProcessTest() loads 48 about blank after every test. 49 (prepareDOMForTagNamesTests): Deleted. 50 * TestWebKitAPI/Tests/WebKitGtk/TestDOMNodeFilter.cpp: 51 (testWebKitDOMNodeFilterTreeWalker): Use new WebViewTest::runWebProcessTest() API. 52 (testWebKitDOMNodeFilterNodeIterator): Ditto. 53 (runTest): Deleted. 54 * TestWebKitAPI/Tests/WebKitGtk/TestDOMXPathNSResolver.cpp: 55 (testWebKitDOMXPathNSResolverNative): Use new WebViewTest::runWebProcessTest() API. 56 (testWebKitDOMXPathNSResolverCustom): Ditto. 57 * TestWebKitAPI/Tests/WebKitGtk/TestEditor.cpp: 58 (testWebKitWebEditorSelectionChanged): Use new WebViewTest::runWebProcessTest() API. 59 * TestWebKitAPI/glib/WebKitGLib/WebViewTest.cpp: 60 (WebViewTest::runWebProcessTest): It now receives the contents, so it automatically loads the view using 61 "webprocess://test" as base URI, used to detect tests in the web process. It also loads about:blank after every 62 test to ensure that window object is cleared. 63 * TestWebKitAPI/glib/WebKitGLib/WebViewTest.h: 64 1 65 2018-03-09 Carlos Garcia Campos <cgarcia@igalia.com> 2 66 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGLib/FrameTest.cpp
r218686 r230401 32 32 WebKitFrame* frame = webkit_web_page_get_main_frame(page); 33 33 g_assert(WEBKIT_IS_FRAME(frame)); 34 assertObjectIsDeletedWhenTestFinishes(G_OBJECT(frame));35 34 g_assert(webkit_frame_is_main_frame(frame)); 36 35 … … 42 41 WebKitFrame* frame = webkit_web_page_get_main_frame(page); 43 42 g_assert(WEBKIT_IS_FRAME(frame)); 44 assertObjectIsDeletedWhenTestFinishes(G_OBJECT(frame));45 43 g_assert_cmpstr(webkit_web_page_get_uri(page), ==, webkit_frame_get_uri(frame)); 46 44 … … 52 50 WebKitFrame* frame = webkit_web_page_get_main_frame(page); 53 51 g_assert(WEBKIT_IS_FRAME(frame)); 54 assertObjectIsDeletedWhenTestFinishes(G_OBJECT(frame));55 52 g_assert(webkit_frame_get_javascript_global_context(frame)); 56 53 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGLib/TestFrame.cpp
r218686 r230401 22 22 #include "WebViewTest.h" 23 23 24 static void webkitFrameTestRun(WebViewTest* test, const char* testName)25 {26 static const char* testHTML = "<html><body></body></html>";27 test->loadHtml(testHTML, 0);28 test->waitUntilLoadFinished();29 30 g_assert(test->runWebProcessTest("WebKitFrame", testName));31 }32 33 24 static void testWebKitFrameMainFrame(WebViewTest* test, gconstpointer) 34 25 { 35 webkitFrameTestRun(test, "main-frame");26 g_assert(test->runWebProcessTest("WebKitFrame", "main-frame")); 36 27 } 37 28 38 29 static void testWebKitFrameURI(WebViewTest* test, gconstpointer) 39 30 { 40 webkitFrameTestRun(test, "uri");31 g_assert(test->runWebProcessTest("WebKitFrame", "uri")); 41 32 } 42 33 43 34 static void testWebKitFrameJavaScriptContext(WebViewTest* test, gconstpointer) 44 35 { 45 webkitFrameTestRun(test, "javascript-context");36 g_assert(test->runWebProcessTest("WebKitFrame", "javascript-context")); 46 37 } 47 38 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGLib/WebProcessTest.cpp
r218685 r230401 21 21 #include "WebProcessTest.h" 22 22 23 #include "WebKitWebExtensionPrivate.h" 23 24 #include <JavaScriptCore/JSRetainPtr.h> 24 25 #include <gio/gio.h> … … 65 66 WebKitWebPage* webPage = WEBKIT_WEB_PAGE(JSObjectGetPrivate(thisObject)); 66 67 g_assert(WEBKIT_IS_WEB_PAGE(webPage)); 67 // Test /WebKitDOMNode/dom-cache is an exception, because it's called 3 times, so 68 // the WebPage is destroyed after the third time. 69 if (g_str_equal(testPath.get(), "WebKitDOMNode/dom-cache")) { 70 static unsigned domCacheTestRunCount = 0; 71 if (++domCacheTestRunCount == 3) 72 WebProcessTest::assertObjectIsDeletedWhenTestFinishes(G_OBJECT(webPage)); 73 } else 74 WebProcessTest::assertObjectIsDeletedWhenTestFinishes(G_OBJECT(webPage)); 68 WebProcessTest::assertObjectIsDeletedWhenTestFinishes(G_OBJECT(webPage)); 75 69 76 70 std::unique_ptr<WebProcessTest> test = WebProcessTest::create(String::fromUTF8(testPath.get())); … … 101 95 static void windowObjectClearedCallback(WebKitScriptWorld* world, WebKitWebPage* webPage, WebKitFrame* frame, WebKitWebExtension* extension) 102 96 { 97 if (g_strcmp0(webkit_web_page_get_uri(webPage), "webprocess://test")) 98 return; 99 103 100 JSGlobalContextRef context = webkit_frame_get_javascript_context_for_script_world(frame, world); 104 101 JSObjectRef globalObject = JSContextGetGlobalObject(context); … … 118 115 extern "C" void webkit_web_extension_initialize(WebKitWebExtension* extension) 119 116 { 117 webkitWebExtensionSetGarbageCollectOnPageDestroy(extension); 120 118 g_signal_connect(webkit_script_world_get_default(), "window-object-cleared", G_CALLBACK(windowObjectClearedCallback), extension); 121 119 } -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/DOMClientRectTest.cpp
r214215 r230401 75 75 g_assert_cmpuint(webkit_dom_client_rect_list_get_length(clientRectList.get()), ==, 1); 76 76 77 WebKitDOMClientRect* clientRect = webkit_dom_client_rect_list_item(clientRectList.get(), 0);78 g_assert(WEBKIT_DOM_IS_CLIENT_RECT(clientRect ));79 assertObjectIsDeletedWhenTestFinishes(G_OBJECT(clientRect ));80 checkClientRectPosition(clientRect );77 GRefPtr<WebKitDOMClientRect> clientRect = adoptGRef(webkit_dom_client_rect_list_item(clientRectList.get(), 0)); 78 g_assert(WEBKIT_DOM_IS_CLIENT_RECT(clientRect.get())); 79 assertObjectIsDeletedWhenTestFinishes(G_OBJECT(clientRect.get())); 80 checkClientRectPosition(clientRect.get()); 81 81 82 82 // Getting the clientRect twice should return the same pointer. 83 g_assert(webkit_dom_client_rect_list_item(clientRectList.get(), 0) == webkit_dom_client_rect_list_item(clientRectList.get(), 0)); 83 GRefPtr<WebKitDOMClientRect> clientRect2 = adoptGRef(webkit_dom_client_rect_list_item(clientRectList.get(), 0)); 84 g_assert(clientRect.get() == clientRect2.get()); 84 85 85 86 return true; -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/TestAutocleanups.cpp
r196844 r230401 45 45 static void testWebProcessAutocleanups(WebViewTest* test, gconstpointer) 46 46 { 47 static const char* testHTML = "<html><body></body></html>";48 test->loadHtml(testHTML, nullptr);49 test->waitUntilLoadFinished();50 51 47 g_assert(test->runWebProcessTest("Autocleanups", "web-process-autocleanups")); 52 48 } -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/TestDOMClientRect.cpp
r214215 r230401 23 23 #include <webkit2/webkit2.h> 24 24 25 static void prepareDOMForClientRectPositionTests(WebViewTest* test) 26 { 27 static const char* testHTML = "<html><head></head><body>" 28 "<style>" 29 " #rect { position: fixed; top: -25px; left: -50px; width: 100px; height: 200px; }" 30 "</style>" 31 "<div id=rect></div></body></html>"; 32 test->loadHtml(testHTML, nullptr); 33 test->waitUntilLoadFinished(); 34 } 25 static const char* testHTML = "<html><head></head><body>" 26 "<style>" 27 " #rect { position: fixed; top: -25px; left: -50px; width: 100px; height: 200px; }" 28 "</style>" 29 "<div id=rect></div></body></html>"; 35 30 36 31 static void testWebKitDOMClientRectDivBoundingClientRectPosition(WebViewTest* test, gconstpointer) 37 32 { 38 prepareDOMForClientRectPositionTests(test); 39 g_assert(test->runWebProcessTest("WebKitDOMClientRect", "div-bounding-client-rect-position")); 33 g_assert(test->runWebProcessTest("WebKitDOMClientRect", "div-bounding-client-rect-position", testHTML)); 40 34 } 41 35 42 36 static void testWebKitDOMClientRectDivClientRectsPositionAndLength(WebViewTest* test, gconstpointer) 43 37 { 44 prepareDOMForClientRectPositionTests(test); 45 g_assert(test->runWebProcessTest("WebKitDOMClientRect", "div-client-rects-position-and-length")); 38 g_assert(test->runWebProcessTest("WebKitDOMClientRect", "div-client-rects-position-and-length", testHTML)); 46 39 } 47 40 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/TestDOMNode.cpp
r190346 r230401 27 27 { 28 28 static const char* testHTML = "<html><head><title>This is the title</title></head><body><p>1</p><p>2</p><p>3</p></body></html>"; 29 test->loadHtml(testHTML, 0); 30 test->waitUntilLoadFinished(); 31 32 g_assert(test->runWebProcessTest("WebKitDOMNode", "hierarchy-navigation")); 29 g_assert(test->runWebProcessTest("WebKitDOMNode", "hierarchy-navigation", testHTML)); 33 30 } 34 31 35 32 static void testWebKitDOMNodeInsertion(WebViewTest* test, gconstpointer) 36 33 { 37 static const char* testHTML = "<html><body></body></html>";38 test->loadHtml(testHTML, 0);39 test->waitUntilLoadFinished();40 41 34 g_assert(test->runWebProcessTest("WebKitDOMNode", "insertion")); 42 35 } 43 36 44 static void prepareDOMForTagNamesTests(WebViewTest* test) 45 { 46 static const char* testHTML = "<html><head></head><body>" 47 "<video id='video' preload='none'>" 48 " <source src='movie.ogg' type='video/ogg'>" 49 " Your browser does not support the video tag." 50 "</video>" 51 "<video id='video2' preload='none'>" 52 " <source src='movie.ogg' type='video/ogg'>" 53 " Your browser does not support the video tag." 54 "</video>" 55 "<input type='hidden' id='test' name='finish' value='false'></body></html>"; 56 test->loadHtml(testHTML, nullptr); 57 test->waitUntilLoadFinished(); 58 } 37 static const char* tagNamesTestHTML = "<html><head></head><body>" 38 "<video id='video' preload='none'>" 39 " <source src='movie.ogg' type='video/ogg'>" 40 " Your browser does not support the video tag." 41 "</video>" 42 "<video id='video2' preload='none'>" 43 " <source src='movie.ogg' type='video/ogg'>" 44 " Your browser does not support the video tag." 45 "</video>" 46 "<input type='hidden' id='test' name='finish' value='false'></body></html>"; 59 47 60 48 static void testWebKitDOMNodeTagNamesNodeList(WebViewTest* test, gconstpointer) 61 49 { 62 prepareDOMForTagNamesTests(test); 63 g_assert(test->runWebProcessTest("WebKitDOMNode", "tag-names-node-list")); 50 g_assert(test->runWebProcessTest("WebKitDOMNode", "tag-names-node-list", tagNamesTestHTML)); 64 51 } 65 52 66 53 static void testWebKitDOMNodeTagNamesHTMLCollection(WebViewTest* test, gconstpointer) 67 54 { 68 prepareDOMForTagNamesTests(test); 69 g_assert(test->runWebProcessTest("WebKitDOMNode", "tag-names-html-collection")); 55 g_assert(test->runWebProcessTest("WebKitDOMNode", "tag-names-html-collection", tagNamesTestHTML)); 70 56 } 71 57 … … 73 59 { 74 60 static const char* testHTML = "<html><body><div id='container'><p>DOM Cache test</p><a id='link href='#'>link</a></div></body></html>"; 75 76 // Run the test 3 times to make sure the DOM objects are correctly released when the 77 // document is detached from the frame for every new document created. 78 for (unsigned i = 0; i < 3; ++i) { 79 test->loadHtml(testHTML, nullptr); 80 test->waitUntilLoadFinished(); 81 82 g_assert(test->runWebProcessTest("WebKitDOMNode", "dom-cache")); 83 } 61 g_assert(test->runWebProcessTest("WebKitDOMNode", "dom-cache", testHTML)); 84 62 } 85 63 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/TestDOMNodeFilter.cpp
r176563 r230401 27 27 "<body><input type='button' name='push' value='push'><input type='button' name='clear' value='clear'><br></body></html>"; 28 28 29 static void runTest(WebViewTest* test, const char* name)30 {31 test->loadHtml(testHTML, nullptr);32 test->waitUntilLoadFinished();33 34 g_assert(test->runWebProcessTest("WebKitDOMNodeFilter", name));35 }36 37 29 static void testWebKitDOMNodeFilterTreeWalker(WebViewTest* test, gconstpointer) 38 30 { 39 runTest(test, "tree-walker");31 g_assert(test->runWebProcessTest("WebKitDOMNodeFilter", "tree-walker", testHTML)); 40 32 } 41 33 42 34 static void testWebKitDOMNodeFilterNodeIterator(WebViewTest* test, gconstpointer) 43 35 { 44 runTest(test, "node-iterator");36 g_assert(test->runWebProcessTest("WebKitDOMNodeFilter", "node-iterator", testHTML)); 45 37 } 46 38 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/TestDOMXPathNSResolver.cpp
r176563 r230401 27 27 { 28 28 static const char* nativeXML = "<root xmlns:foo='http://www.example.org'><foo:child>SUCCESS</foo:child></root>"; 29 GRefPtr<GBytes> bytes = adoptGRef(g_bytes_new_static(nativeXML, strlen(nativeXML))); 30 test->loadBytes(bytes.get(), "text/xml", nullptr, nullptr); 31 test->waitUntilLoadFinished(); 32 g_assert(test->runWebProcessTest("WebKitDOMXPathNSResolver", "native")); 29 g_assert(test->runWebProcessTest("WebKitDOMXPathNSResolver", "native", nativeXML, "text/xml")); 33 30 } 34 31 … … 36 33 { 37 34 static const char* customXML = "<root xmlns='http://www.example.com'><child>SUCCESS</child></root>"; 38 GRefPtr<GBytes> bytes = adoptGRef(g_bytes_new_static(customXML, strlen(customXML))); 39 test->loadBytes(bytes.get(), "text/xml", nullptr, nullptr); 40 test->waitUntilLoadFinished(); 41 g_assert(test->runWebProcessTest("WebKitDOMXPathNSResolver", "custom")); 35 g_assert(test->runWebProcessTest("WebKitDOMXPathNSResolver", "custom", customXML, "text/xml")); 42 36 } 43 37 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/Tests/WebKitGtk/TestEditor.cpp
r187024 r230401 27 27 { 28 28 static const gchar* testHTML = "<html><body>All work and no play make Jack a dull boy.</body></html>"; 29 test->loadHtml(testHTML, nullptr); 30 test->waitUntilLoadFinished(); 31 32 g_assert(test->runWebProcessTest("WebKitWebEditor", "selection-changed")); 29 g_assert(test->runWebProcessTest("WebKitWebEditor", "selection-changed", testHTML)); 33 30 } 34 31 -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/glib/WebKitGLib/WebViewTest.cpp
r229458 r230401 381 381 #endif 382 382 383 bool WebViewTest::runWebProcessTest(const char* suiteName, const char* testName) 384 { 383 bool WebViewTest::runWebProcessTest(const char* suiteName, const char* testName, const char* contents, const char* contentType) 384 { 385 if (!contentType) { 386 static const char* emptyHTML = "<html><body></body></html>"; 387 loadHtml(contents ? contents : emptyHTML, "webprocess://test"); 388 } else { 389 GRefPtr<GBytes> bytes = adoptGRef(g_bytes_new_static(contents, strlen(contents))); 390 loadBytes(bytes.get(), contentType, nullptr, "webprocess://test"); 391 } 392 waitUntilLoadFinished(); 393 385 394 GUniquePtr<char> script(g_strdup_printf("WebProcessTestRunner.runTest('%s/%s');", suiteName, testName)); 386 395 GUniqueOutPtr<GError> error; 387 396 WebKitJavascriptResult* javascriptResult = runJavaScriptAndWaitUntilFinished(script.get(), &error.outPtr()); 388 397 g_assert(!error); 398 loadURI("about:blank"); 399 waitUntilLoadFinished(); 389 400 return javascriptResultToBoolean(javascriptResult); 390 401 } -
releases/WebKitGTK/webkit-2.20/Tools/TestWebKitAPI/glib/WebKitGLib/WebViewTest.h
r229458 r230401 84 84 #endif 85 85 86 bool runWebProcessTest(const char* suiteName, const char* testName );86 bool runWebProcessTest(const char* suiteName, const char* testName, const char* contents = nullptr, const char* contentType = nullptr); 87 87 88 88 // Prohibit overrides because this is called when the web view is created
Note: See TracChangeset
for help on using the changeset viewer.