Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(241)

Unified Diff: LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html

Issue 1184563002: Fix broken preferred widths optimization involving subtree layout roots (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove the code! Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | LayoutTests/fast/layout/nested-subtree-layout-preferred-widths-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html
diff --git a/LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html b/LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html
new file mode 100644
index 0000000000000000000000000000000000000000..5118abded823be1f3b947e45517f022c866199d2
--- /dev/null
+++ b/LayoutTests/fast/layout/nested-subtree-layout-preferred-widths.html
@@ -0,0 +1,40 @@
+<!DOCTYPE html>
+<style>
+div {
+ overflow: hidden;
+}
+#root {
+ width: 200px;
+ height: 400px;
+ background: red;
+}
+#content {
+ background: green;
+ width: 100%;
+ height: 400px;
+ display: block;
+}
+#container {
+ width: 400px;
+ height: 400px;
+}
+</style>
+<script src="../../resources/check-layout.js"></script>
+<div>
+ crbug.com/497178: This test ensures we properly recompute preferred widths for
+ nested subtree roots. If this test is ever flaky, it should be considered
+ failing due the the non-deterministic way we iterate over subtree layout roots.
+</div>
+<div id="container">
+ <div id="root">
+ <div data-expected-width="400" id="content">OriginalText</div>
+ </div>
+</div>
+<script>
+document.body.offsetTop;
+var rootElement = document.getElementById("root");
+var content = document.getElementById("content");
+content.innerText = "";
+rootElement.style.width = "400px";
+checkLayout("#content");
+</script>
« no previous file with comments | « no previous file | LayoutTests/fast/layout/nested-subtree-layout-preferred-widths-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698