9 <script src=
"resources/autosizingTest.js"></script>
12 var fontSizeOriginal
= getAutosizedFontSize();
13 setWindowSizeOverride(520, 480);
14 var fontSizeUpdated
= getAutosizedFontSize();
16 if (fontSizeOriginal
!= fontSizeUpdated
)
17 document
.write('PASS');
19 document
.write('FAIL. Expected font size to change but it stayed at ' + fontSizeOriginal
);
20 if (window
.testRunner
)
21 testRunner
.dumpAsText();
24 function getAutosizedFontSize() {
25 var autosizeContainer
= document
.getElementById('autosize');
26 var forceLayout
= autosizeContainer
.offsetWidth
;
27 return parseInt(window
.getComputedStyle(autosizeContainer
).fontSize
);
31 <body onload=
"test()">
33 This test passes if this text changes size due to autosizing after a dynamic window size change occurs. I'm just adding lines so this text is long enough to autosize. I'm just adding lines so this text is long enough to autosize. I'm just adding lines so this text is long enough to autosize. I'm just adding lines so this text is long enough to autosize. I'm just adding lines so this text is long enough to autosize. I'm just adding lines so this text is long enough to autosize.