Title: [157291] trunk/LayoutTests
- Revision
- 157291
- Author
- [email protected]
- Date
- 2013-10-10 23:17:10 -0700 (Thu, 10 Oct 2013)
Log Message
Layout Test fast/css/font-face-download-error.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=122636
Reviewed by Darin Adler.
* fast/css/font-face-download-error-expected.txt: TEST COMPLETE is now printed
after the test is complete.
* fast/css/font-face-download-error.html: Changed to properly wait for fonts to load.
Also, updated to use a proper async test implementation.
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (157290 => 157291)
--- trunk/LayoutTests/ChangeLog 2013-10-11 06:16:23 UTC (rev 157290)
+++ trunk/LayoutTests/ChangeLog 2013-10-11 06:17:10 UTC (rev 157291)
@@ -1,3 +1,16 @@
+2013-10-10 Alexey Proskuryakov <[email protected]>
+
+ Layout Test fast/css/font-face-download-error.html is flaky
+ https://bugs.webkit.org/show_bug.cgi?id=122636
+
+ Reviewed by Darin Adler.
+
+ * fast/css/font-face-download-error-expected.txt: TEST COMPLETE is now printed
+ after the test is complete.
+
+ * fast/css/font-face-download-error.html: Changed to properly wait for fonts to load.
+ Also, updated to use a proper async test implementation.
+
2013-10-10 Brendan Long <[email protected]>
Track controls show metadata and chapter tracks
Modified: trunk/LayoutTests/fast/css/font-face-download-error-expected.txt (157290 => 157291)
--- trunk/LayoutTests/fast/css/font-face-download-error-expected.txt 2013-10-11 06:16:23 UTC (rev 157290)
+++ trunk/LayoutTests/fast/css/font-face-download-error-expected.txt 2013-10-11 06:17:10 UTC (rev 157291)
@@ -22,9 +22,6 @@
jjjjjjjjjj test_3_1
jjjjjjjjjj ref_3_1
-PASS successfullyParsed is true
-
-TEST COMPLETE
PASS document.getElementById('test_0_0').offsetWidth is document.getElementById('ref_0_0').offsetWidth
PASS document.getElementById('test_0_1').offsetWidth is document.getElementById('ref_0_1').offsetWidth
PASS document.getElementById('test_1_0').offsetWidth is document.getElementById('ref_1_0').offsetWidth
@@ -33,4 +30,7 @@
PASS document.getElementById('test_2_1').offsetWidth is document.getElementById('ref_2_1').offsetWidth
PASS document.getElementById('test_3_0').offsetWidth is document.getElementById('ref_3_0').offsetWidth
PASS document.getElementById('test_3_1').offsetWidth is document.getElementById('ref_3_1').offsetWidth
+PASS successfullyParsed is true
+TEST COMPLETE
+
Modified: trunk/LayoutTests/fast/css/font-face-download-error.html (157290 => 157291)
--- trunk/LayoutTests/fast/css/font-face-download-error.html 2013-10-11 06:16:23 UTC (rev 157290)
+++ trunk/LayoutTests/fast/css/font-face-download-error.html 2013-10-11 06:17:10 UTC (rev 157291)
@@ -55,15 +55,14 @@
</style>
<script src=""
</head>
-<body _onload_="runTest()">
+<body _onload_="test()">
<div id="description"></div>
<div id="tests"></div>
<div id="console"></div>
<div id="out"></div>
<script>
-if (window.testRunner)
- window.testRunner.waitUntilDone();
+jsTestIsAsync = true;
description("If no font resources are available for an @font-face rule due to download errors, the rule must be ignored but others must remain in effect.");
@@ -109,8 +108,7 @@
shouldBe("document.getElementById('" + testId(mainTestId, subTestId) + "').offsetWidth", "document.getElementById('" + refId(mainTestId, subTestId) + "').offsetWidth");
}
}
- if (window.testRunner)
- window.testRunner.notifyDone();
+ finishJSTest();
}
for (var mainTestId = 0; mainTestId < expectedResults.length; mainTestId++) {
@@ -123,12 +121,9 @@
testsElement.appendChild(document.createElement("br"));
}
-// We need to run tests after the font downloading succeeded or failed.
-// Using a timer is not ideal, but there seems to be no better options.
-function runTest()
-{
- window.setTimeout(test, 200);
-}
+// Force layout, so that fonts begin to load before the document finishes loading, and thus delay the load event.
+document.body.offsetTop;
+
</script>
<script src=""
</body>
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes