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

Unified Diff: third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly.html

Issue 1480233007: Don't update the logical width when a scrollbar gets added (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2564
Patch Set: Created 5 years 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 | third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly.html
diff --git a/third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly.html b/third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly.html
index fba0716229e34ea0929c9ffce632691ea6a260b3..b7cf506354bcb6ddcbdde3fe5e43368d5cb23e6c 100644
--- a/third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly.html
+++ b/third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly.html
@@ -51,6 +51,11 @@
</div>
</div>
+<!-- This div is only for measuring scrollbar size -->
+<div id="measure" style="height: 100px; width: 100px; display: inline-box; overflow: auto;">
+ <div style="min-height: 300px;"></div>
+</div>
+
<script>
description("When a block inside a flexbox adds scrollbars due to overflow, the parent flexbox should re-flex based on the child size including scrollbars.");
@@ -60,8 +65,10 @@
var intrinsicHeightBox = document.querySelector('.intrinsic-height-box');
shouldBe("intrinsicHeightBox.clientHeight", "intrinsicHeightBox.scrollHeight");
- // This is expected to fail; see:
- // https://codereview.chromium.org/1295933003/#msg1
+ var measure = document.getElementById('measure');
+ var scrollbarSize = measure.offsetWidth - measure.clientWidth;
+ shouldNotBe("scrollbarSize", "0");
+
var vbox = document.querySelector('.vbox');
- shouldBe("vbox.clientWidth", "vbox.scrollWidth");
+ shouldBe("vbox.clientWidth", "100 - scrollbarSize");
</script>
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/css3/flexbox/overflow-auto-resizes-correctly-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698