Title: [281204] branches/safari-612.1.27.0-branch/LayoutTests
- Revision
- 281204
- Author
- repst...@apple.com
- Date
- 2021-08-18 11:32:02 -0700 (Wed, 18 Aug 2021)
Log Message
Cherry-pick r281195. rdar://problem/82083653
Add a layout test for webkit.org/b/229200
https://bugs.webkit.org/show_bug.cgi?id=229222
rdar://81636256
Reviewed by Simon Fraser.
Add a layout test to exercise the hang fixed in bug #229200. This test can be manually run by opening it in
browser and verifying that the page does not hang (and outputs the expected PASS messages).
* fast/canvas/draw-text-repeatedly-into-disconnected-canvas-expected.txt: Added.
* fast/canvas/draw-text-repeatedly-into-disconnected-canvas.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@281195 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Modified Paths
Added Paths
Diff
Modified: branches/safari-612.1.27.0-branch/LayoutTests/ChangeLog (281203 => 281204)
--- branches/safari-612.1.27.0-branch/LayoutTests/ChangeLog 2021-08-18 18:31:59 UTC (rev 281203)
+++ branches/safari-612.1.27.0-branch/LayoutTests/ChangeLog 2021-08-18 18:32:02 UTC (rev 281204)
@@ -1,3 +1,36 @@
+2021-08-18 Russell Epstein <repst...@apple.com>
+
+ Cherry-pick r281195. rdar://problem/82083653
+
+ Add a layout test for webkit.org/b/229200
+ https://bugs.webkit.org/show_bug.cgi?id=229222
+ rdar://81636256
+
+ Reviewed by Simon Fraser.
+
+ Add a layout test to exercise the hang fixed in bug #229200. This test can be manually run by opening it in
+ browser and verifying that the page does not hang (and outputs the expected PASS messages).
+
+ * fast/canvas/draw-text-repeatedly-into-disconnected-canvas-expected.txt: Added.
+ * fast/canvas/draw-text-repeatedly-into-disconnected-canvas.html: Added.
+
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@281195 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2021-08-18 Wenson Hsieh <wenson_hs...@apple.com>
+
+ Add a layout test for webkit.org/b/229200
+ https://bugs.webkit.org/show_bug.cgi?id=229222
+ rdar://81636256
+
+ Reviewed by Simon Fraser.
+
+ Add a layout test to exercise the hang fixed in bug #229200. This test can be manually run by opening it in
+ browser and verifying that the page does not hang (and outputs the expected PASS messages).
+
+ * fast/canvas/draw-text-repeatedly-into-disconnected-canvas-expected.txt: Added.
+ * fast/canvas/draw-text-repeatedly-into-disconnected-canvas.html: Added.
+
2021-08-12 Alan Coon <alanc...@apple.com>
Cherry-pick r280931. rdar://problem/81852494
Added: branches/safari-612.1.27.0-branch/LayoutTests/fast/canvas/draw-text-repeatedly-into-disconnected-canvas-expected.txt (0 => 281204)
--- branches/safari-612.1.27.0-branch/LayoutTests/fast/canvas/draw-text-repeatedly-into-disconnected-canvas-expected.txt (rev 0)
+++ branches/safari-612.1.27.0-branch/LayoutTests/fast/canvas/draw-text-repeatedly-into-disconnected-canvas-expected.txt 2021-08-18 18:32:02 UTC (rev 281204)
@@ -0,0 +1,5 @@
+PASS Done painting
+PASS successfullyParsed is true
+
+TEST COMPLETE
+
Added: branches/safari-612.1.27.0-branch/LayoutTests/fast/canvas/draw-text-repeatedly-into-disconnected-canvas.html (0 => 281204)
--- branches/safari-612.1.27.0-branch/LayoutTests/fast/canvas/draw-text-repeatedly-into-disconnected-canvas.html (rev 0)
+++ branches/safari-612.1.27.0-branch/LayoutTests/fast/canvas/draw-text-repeatedly-into-disconnected-canvas.html 2021-08-18 18:32:02 UTC (rev 281204)
@@ -0,0 +1,61 @@
+<!DOCTYPE html>
+<html>
+<head>
+<script src=""
+<script src=""
+<script>
+jsTestIsAsync = true;
+addEventListener("load", async () => {
+ await document.fonts.load("16px Ahem");
+
+ for (let i = 0; i < 3; ++i)
+ await paintIntoCanvas();
+
+ await paintIntoCanvas(document.getElementById("final-target"));
+
+ testPassed("Done painting");
+ finishJSTest();
+});
+
+async function paintIntoCanvas(target) {
+ let canvas = target || document.createElement("canvas");
+ let context = canvas.getContext("2d");
+
+ context.font = "16px Ahem";
+ context.strokeText("Hello world", 10, 10);
+ context.strokeText("Hello world", 20, 20);
+
+ for (let i = 0; i < 5; ++i)
+ await UIHelper.renderingUpdate();
+
+ delete context;
+ delete canvas;
+ gc();
+}
+
+function gc() {
+ if (window.GCController)
+ return GCController.collect();
+
+ let strings = [];
+ for (let i = 0; i < 1000000; ++i)
+ strings.push(new String(i));
+}
+</script>
+<style>
+@font-face {
+ font-family: Ahem;
+ src: url("../../resources/Ahem.ttf");
+}
+
+canvas {
+ width: 400px;
+ height: 400px;
+ margin-top: 0;
+}
+</style>
+</head>
+<body>
+ <canvas width="400" height="400" id="final-target"></canvas>
+</body>
+</html>
\ No newline at end of file
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes