Changeset 83823 in webkit


Ignore:
Timestamp:
Apr 14, 2011 1:27:13 AM (13 years ago)
Author:
tonyg@chromium.org
Message:

2011-04-14 Tony Gentilcore <tonyg@chromium.org>

Reviewed by Kent Tamura.

[chromium] http/tests/loading/preload-append-scan.php fails
https://bugs.webkit.org/show_bug.cgi?id=58352

On chromium, onload-vs-immediate-refresh always caused the subsequent test to fail
with an additional didFinishLoadForFrame message. This was because the test
navigates via a refresh, but did not actually wait for the navigation to complete.

This patch fixes that by adding a waitUntilDone() and calling notifyDone() after the
redirect target page loads. Now the log for this test shows both navigations and no
part of the navigation leaks into the next test.

Also, since dumpAsText() shows alerts, there was no reason to write vs. alert the
SUCCESS message.

  • http/tests/loading/onload-vs-immediate-refresh-expected.txt:
  • http/tests/loading/onload-vs-immediate-refresh.pl:
  • platform/chromium/test_expectations.txt:
Location:
trunk/LayoutTests
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r83822 r83823  
     12011-04-14  Tony Gentilcore  <tonyg@chromium.org>
     2
     3        Reviewed by Kent Tamura.
     4
     5        [chromium] http/tests/loading/preload-append-scan.php fails
     6        https://bugs.webkit.org/show_bug.cgi?id=58352
     7
     8        On chromium, onload-vs-immediate-refresh always caused the subsequent test to fail
     9        with an additional didFinishLoadForFrame message. This was because the test
     10        navigates via a refresh, but did not actually wait for the navigation to complete.
     11
     12        This patch fixes that by adding a waitUntilDone() and calling notifyDone() after the
     13        redirect target page loads. Now the log for this test shows both navigations and no
     14        part of the navigation leaks into the next test.
     15
     16        Also, since dumpAsText() shows alerts, there was no reason to write vs. alert the
     17        SUCCESS message.
     18
     19        * http/tests/loading/onload-vs-immediate-refresh-expected.txt:
     20        * http/tests/loading/onload-vs-immediate-refresh.pl:
     21        * platform/chromium/test_expectations.txt:
     22
    1232011-04-14  James Robinson  <jamesr@chromium.org>
    224
  • trunk/LayoutTests/http/tests/loading/onload-vs-immediate-refresh-expected.txt

    r39097 r83823  
    11main frame - didStartProvisionalLoadForFrame
     2main frame - didCommitLoadForFrame
     3main frame - didFinishDocumentLoadForFrame
     4ALERT: SUCCESS
     5main frame - willPerformClientRedirectToURL: data:text/html,%3Cbody%20onload='if(window.layoutTestController)layoutTestController.notifyDone();'%3EYou%20should%20have%20seen%20an%20alert.
     6main frame - didHandleOnloadEventsForFrame
     7main frame - didFinishLoadForFrame
     8main frame - didStartProvisionalLoadForFrame
     9main frame - didCancelClientRedirectForFrame
    210main frame - didCommitLoadForFrame
    311main frame - didFinishDocumentLoadForFrame
    412main frame - didHandleOnloadEventsForFrame
    513main frame - didFinishLoadForFrame
    6 SUCCESS
     14You should have seen an alert.
  • trunk/LayoutTests/http/tests/loading/onload-vs-immediate-refresh.pl

    r27986 r83823  
    77$| = 1;
    88
    9 print "Refresh: 0;url=data:text/plain,You should have seen an alert.\r\n";
     9print "Refresh: 0;url=data:text/html,<body onload='if (window.layoutTestController) layoutTestController.notifyDone();'>You should have seen an alert.\r\n";
    1010print "Content-Type: text/html\r\n";
    1111print "\r\n";
     
    1515<head>
    1616<script>
    17 if (window.layoutTestController)
     17if (window.layoutTestController) {
    1818    layoutTestController.dumpAsText();
     19    layoutTestController.waitUntilDone();
     20}
    1921</script>
    20 <meta http-equiv="refresh" content="0;url=data:text/plain,You should have seen an alert.">
     22<meta http-equiv="refresh" content="0;url=data:text/html,%3Cbody%20onload='if(window.layoutTestController)layoutTestController.notifyDone();'%3EYou%20should%20have%20seen%20an%20alert.">
    2123</head>
    2224EOF
     
    2729
    2830print << "EOF";
    29 <body onload="if (window.layoutTestController) document.write('<p>SUCCESS</p>'); else alert('SUCCESS');">
     31<body onload="alert('SUCCESS');">
    3032</body>
    3133</html>
  • trunk/LayoutTests/platform/chromium/test_expectations.txt

    r83822 r83823  
    25922592BUG_DRT : http/tests/misc/slow-loading-image-in-pattern.html = IMAGE
    25932593
    2594 // Extra didFinishDocumentLoadForFrame line.
    2595 // The first didFinishDocumentLoadForFrame line is for the previous test document.
    2596 BUG_DRT WIN MAC LINUX : http/tests/loading/preload-img-test.html = TEXT TIMEOUT PASS
    2597 
    25982594// Flaky since 2010-09-17?
    25992595BUGCR57950 WIN XP : svg/batik/text/verticalText.svg = CRASH PASS
     
    33183314// The merged test is flaky on Chromium since then.
    33193315BUGCR78998 DEBUG : fast/frames/frame-element-name.html = TEXT PASS
    3320 // Added in http://trac.webkit.org/changeset/83321/. It's very flaky.
    3321 BUGCR79006 : http/tests/loading/preload-append-scan.php = TEXT PASS
    33223316
    33233317// Windows 7 failures that need triaging and probably mostly just need
Note: See TracChangeset for help on using the changeset viewer.