[Modern Media Controls] Turn media/modern-media-controls/ios-inline-media-controls...
[WebKit-https.git] / LayoutTests / media / video-load-preload-metadata-naturalsize.html
1 <html>
2     <head>
3         <script src="media-file.js"></script>
4         <script src="video-test.js"></script>
5         <script>
6             var playbackStarted = false;
7             function start()
8             {
9                 findMediaElement();
10                 video.src = findMediaFile("video", "content/test");
11
12                 testExpected("video.preload", "metadata");
13                 waitForEvent('loadedmetadata', onLoadedMetadata);
14                 failTestIn(2000);
15             }
16             function onLoadedMetadata()
17             {
18                 testExpected("video.videoWidth", 320);
19                 testExpected("video.videoHeight", 240);
20                 endTest();
21             }
22         </script>
23     </head>
24
25     <body onload="start()">
26         <video controls preload="metadata"></video>
27         <p>Test that preload="metadata" results in the correct naturalSize.</p>
28     </body>
29 </html>