Title: [153964] trunk/Tools
Revision
153964
Author
[email protected]
Date
2013-08-12 16:42:27 -0700 (Mon, 12 Aug 2013)

Log Message

https://bugs.webkit.org/show_bug.cgi?id=119693
[Mac] security/contentSecurityPolicy/connect-src-websocket-blocked.html is flaky
because of connect-src-websocket-allowed.html

Reviewed by Darin Adler.

Starting a load of about:blank and immediately stopping it cancels outstanding
resource loads, but the page has to transition to committed state to have timers
or WebSockets stopped too.

* DumpRenderTree/mac/DumpRenderTree.mm: (runTest): Use a synchronous load to
ensure that transition to committed state happens before we start the next test.

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (153963 => 153964)


--- trunk/Tools/ChangeLog	2013-08-12 23:41:26 UTC (rev 153963)
+++ trunk/Tools/ChangeLog	2013-08-12 23:42:27 UTC (rev 153964)
@@ -1,3 +1,18 @@
+2013-08-12  Alexey Proskuryakov  <[email protected]>
+
+        https://bugs.webkit.org/show_bug.cgi?id=119693
+        [Mac] security/contentSecurityPolicy/connect-src-websocket-blocked.html is flaky
+        because of connect-src-websocket-allowed.html
+
+        Reviewed by Darin Adler.
+
+        Starting a load of about:blank and immediately stopping it cancels outstanding
+        resource loads, but the page has to transition to committed state to have timers
+        or WebSockets stopped too.
+
+        * DumpRenderTree/mac/DumpRenderTree.mm: (runTest): Use a synchronous load to
+        ensure that transition to committed state happens before we start the next test.
+
 2013-08-12  Beth Dakin  <[email protected]>
 
         The LayoutMilestones didLayout callback should only fire for the main frame

Modified: trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm (153963 => 153964)


--- trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm	2013-08-12 23:41:26 UTC (rev 153963)
+++ trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm	2013-08-12 23:42:27 UTC (rev 153964)
@@ -1442,8 +1442,9 @@
 
     resetWebViewToConsistentStateBeforeTesting();
 
-    [mainFrame loadHTMLString:@"<html></html>" baseURL:[NSURL URLWithString:@"about:blank"]];
-    [mainFrame stopLoading];
+    // Loading an empty request synchronously replaces the document with a blank one, which is necessary
+    // to stop timers, WebSockets and other activity that could otherwise spill output into next test's results.
+    [mainFrame loadRequest:[NSURLRequest requestWithURL:[NSURL URLWithString:@""]]];
 
     [pool release];
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to