Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / autoresize / turn-off-autoresize.html
blob0692ad0d200527ded0ca1f63c8c7791fea36c749
1 <!doctype html>
2 <html>
3 <script src='resources/autoresize-util.js'></script>
4 <script>
5 function runTest()
7 if (window.testRunner) {
8 testRunner.useUnfortunateSynchronousResizeMode();
9 testRunner.enableAutoResizeMode(10, 10, 1000, 1000);
10 testRunner.dumpAsText();
12 shouldBe('document.body.clientWidth', 'window.innerWidth');
13 shouldBe('document.body.clientHeight', 'window.innerHeight');
14 shouldBe('document.scrollingElement.scrollWidth', 'window.innerWidth');
15 shouldBe('document.scrollingElement.scrollHeight', 'window.innerHeight');
16 shouldBe('window.innerWidth', 'window.outerWidth');
17 shouldBe('window.innerHeight', 'window.outerHeight');
18 if (window.testRunner)
19 testRunner.disableAutoResizeMode(200, 200);
21 shouldBe('window.outerWidth', 200);
22 shouldBe('window.outerHeight', 200);
23 document.body.style.width = '100px';
24 shouldBe('window.outerWidth', 200);
26 log('DONE');
28 </script>
29 <body onload="runTest()" style="margin:0; width:900px">
30 This test verifies that turning off auto resize functions correctly. It only works when run in dumprendertree as it relies on having auto-resize function available.
31 <br>
32 <br>
33 When it succeeds, there should be a series of PASS messages followed by a DONE message.
34 <br>
35 <br>
36 <div id='result'>
37 </div>
38 </body>
39 </html>