Index: third_party/WebKit/LayoutTests/fast/block/float/clear-intruding-floats-when-moving-to-inline-parent.html |
diff --git a/third_party/WebKit/LayoutTests/fast/block/float/clear-intruding-floats-when-moving-to-inline-parent.html b/third_party/WebKit/LayoutTests/fast/block/float/clear-intruding-floats-when-moving-to-inline-parent.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..42aab5c01fdc9f2bb1a08ef91c07bc065880d4be |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/fast/block/float/clear-intruding-floats-when-moving-to-inline-parent.html |
@@ -0,0 +1,30 @@ |
+<!DOCTYPE html> |
+<script src="../../../resources/js-test.js"></script> |
+<div></div> |
+<span></span> |
+<div id="killMe" style="float:right; width:100px; height:100px;"></div> |
+<div id="container"> |
+ <canvas id="canvas" style="display:block;"></canvas> |
+</div> |
+<script> |
+ // Trigger layout. |
+ document.body.offsetTop; |
+ |
+ // Delete the float. |
+ document.getElementById("killMe").style.display = "none"; |
+ |
+ // Take it out of normal flow and establish a new block formatting |
+ // context, so that the preceding float (which no longer exists, by |
+ // the way) can no longer intrude. Not being in normal flow anymore |
+ // also means that it can be moved into an adjacent anonymous block if |
+ // one exists. |
+ document.getElementById("container").style.position = 'absolute'; |
+ |
+ // Trigger style recalculation, but NOT layout. |
+ getComputedStyle(document.getElementById("container")).color; |
+ |
+ // When zoom changes, LayoutReplaced::styleDidChange() will call |
+ // intrinsicSizeChanged(), which will do an out-of-course layout on the canvas element. |
+ document.getElementById("canvas").style.zoom = 0.50; |
+ testPassed("crbug.com/562208: Clear intruding floats when moving child to inline parent."); |
mstensho (USE GERRIT)
2015/12/07 14:07:35
This is a crash test. Could you make that clearer?
|
+</script> |