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

Side by Side Diff: LayoutTests/fast/images/exif-orientation-height-image-document-title.html

Issue 174073006: Add a layout test for ImageDocument document.title (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: Created 6 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 unified diff | Download patch
« no previous file with comments | « no previous file | LayoutTests/fast/images/exif-orientation-height-image-document-title-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <script>
2 var newwindow;
3 if (window.testRunner) {
4 testRunner.dumpAsText();
5 testRunner.setCanOpenWindows();
6 testRunner.setPopupBlockingEnabled(false);
7 testRunner.setCloseRemainingWindowsWhenComplete(true);
8 testRunner.waitUntilDone();
9 }
10
11 function loadImageInNewWindow()
12 {
13 newwindow = window.open('resources/jpeg-height-exif-orientation.jpg');
14 if (window.testRunner)
15 testRunner.useUnfortunateSynchronousResizeMode();
16
17 newwindow.onload = function() {
18 newwindow.onresize = function() {
19 var image = newwindow.document.querySelector('img');
20 if (image.clientWidth == 0) {
21 // On GTK+, sometimes the resize callback fires before the GTK
22 // window has finished resizing. If that happens, try to resize
23 // again.
24 setTimeout(function() {
25 newwindow.resizeTo(360, 360);
26 }, 0);
27 return;
28 } else {
29 newwindow.location.reload();
30 setTimeout(function() {
31 document.write(newwindow.document.title);
Noel Gordon 2014/02/21 05:26:45 Can you think of a way to write this test that avo
32 testRunner.notifyDone();
33 }, 1000);
34 }
35 };
36 newwindow.resizeTo(360, 360);
37 };
38 }
39
40 loadImageInNewWindow();
41 </script>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/fast/images/exif-orientation-height-image-document-title-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698