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

Unified Diff: third_party/WebKit/LayoutTests/svg/custom/size-follows-container-size.html

Issue 1729073002: Update SVG tests ahead of offset* removal (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update flexitem.html and grid-item-display.html too Created 4 years, 10 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 | « third_party/WebKit/LayoutTests/svg/custom/animate-svgsvgelement.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/svg/custom/size-follows-container-size.html
diff --git a/third_party/WebKit/LayoutTests/svg/custom/size-follows-container-size.html b/third_party/WebKit/LayoutTests/svg/custom/size-follows-container-size.html
index eaa8c0d82fcb9cfbdb39d32b896d69f629ef5161..3ae86c3956b105f325f0169f98b4d74d7f854489 100644
--- a/third_party/WebKit/LayoutTests/svg/custom/size-follows-container-size.html
+++ b/third_party/WebKit/LayoutTests/svg/custom/size-follows-container-size.html
@@ -15,14 +15,16 @@
requestAnimationFrame(function() {
document.querySelector('div').style.width = "1000px";
inc_test.step(function() {
- assert_equals(document.querySelector('svg').offsetWidth, 1000);
- assert_equals(document.querySelector('svg').offsetHeight, 1000);
+ var rect = document.querySelector('svg').getBoundingClientRect();
+ assert_equals(rect.width, 1000);
+ assert_equals(rect.height, 1000);
});
inc_test.done();
document.querySelector('div').style.width = "100px";
dec_test.step(function() {
- assert_equals(document.querySelector('svg').offsetWidth, 100);
- assert_equals(document.querySelector('svg').offsetHeight, 100);
+ var rect = document.querySelector('svg').getBoundingClientRect();
+ assert_equals(rect.width, 100);
+ assert_equals(rect.height, 100);
});
dec_test.done();
});
« no previous file with comments | « third_party/WebKit/LayoutTests/svg/custom/animate-svgsvgelement.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698