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

Unified Diff: LayoutTests/fast/block/float/float-not-removed-crash2.html

Issue 14759010: Fix the float logic to not return an anonymous block ancestor (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Update as per Julien's comments. Created 7 years, 7 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
Index: LayoutTests/fast/block/float/float-not-removed-crash2.html
diff --git a/LayoutTests/fast/block/float/float-not-removed-crash2.html b/LayoutTests/fast/block/float/float-not-removed-crash2.html
new file mode 100755
index 0000000000000000000000000000000000000000..5ab72a0c95c2780061a2764f45d22fb3c4103523
--- /dev/null
+++ b/LayoutTests/fast/block/float/float-not-removed-crash2.html
@@ -0,0 +1,47 @@
+<html>
Julien - ping for review 2013/05/07 18:43:20 DOCTYPE per favor!
+<body style="display: -webkit-flex;">
+<i>
+<div> </div><row>
+<source id=test style="float: right; -webkit-padding-before: 238px;">A</source>
Julien - ping for review 2013/05/07 18:43:20 s/-webkit-padding-before/padding-top/ (just remove
+</i>
+<div style="-webkit-logical-height: 188;"></div>
Julien - ping for review 2013/05/07 18:43:20 s/-webkit-logical-height/height/
+<style>
+.class1 {
+ -webkit-logical-width: 51667px;
Julien - ping for review 2013/05/07 18:43:20 s/-webkit-logical-width/width/
+}
+</style>
+<script>
+if (window.testRunner)
+ testRunner.dumpAsText();
+
+function reference(domNode) {
+ this.domNode = domNode;
+}
Julien - ping for review 2013/05/07 18:43:20 This wrapper is useless and should be removed.
+
+function walk(a, currentPrefix, index, domNode) {
Julien - ping for review 2013/05/07 18:43:20 walk() is overly complicated for no good reason. C
+ if (domNode == null)
+ return;
+ newPrefix = currentPrefix + "_" + index;
+ walk(a, currentPrefix, index + 1, domNode.nextSibling);
+ walk(a, newPrefix, 0, domNode.firstChild);
+ a[newPrefix] = new reference(domNode);
+}
+
+function clear() {
+ var a = new Array();
+ walk(a, "", 0, document.documentElement);
+ for(key in a) {
+ a[key].domNode.parentNode.removeChild(a[key].domNode);
+ if (document.documentElement)
+ document.documentElement.offsetTop;
+ }
+}
+
+document.documentElement.offsetTop;
+test.setAttribute("class", "class1");
+document.documentElement.offsetTop;
+clear();
+alert("PASS. WebKit didn't crash.");
+</script>
+</body>
+</html>

Powered by Google App Engine
This is Rietveld 408576698