| OLD | NEW |
| (Empty) |
| 1 <!DOCTYPE html> | |
| 2 <title>HTMLImageElement.width/height returns styled dimensions.</title> | |
| 3 <script src="../../resources/testharness.js"></script> | |
| 4 <script src="../../resources/testharnessreport.js"></script> | |
| 5 <style> | |
| 6 img { | |
| 7 width: 200px; | |
| 8 height: 200px; | |
| 9 } | |
| 10 </style> | |
| 11 <img src="resources/test-load.jpg" width="100" height="100"> | |
| 12 <script> | |
| 13 test(function() { | |
| 14 var image = document.querySelector("img"); | |
| 15 assert_equals(image.width, 200); | |
| 16 assert_equals(image.height, 200); | |
| 17 var rect = image.getBoundingClientRect(); | |
| 18 assert_equals(rect.width, 200); | |
| 19 assert_equals(rect.height, 200); | |
| 20 }); | |
| 21 </script> | |
| OLD | NEW |