blob: aa2e5fb9e770989a8f413465fffd88a0ac58c46b [file] [log] [blame]
<html>
<head>
<script src="media-file.js"></script>
<!-- TODO(foolip): Convert test to testharness.js. crbug.com/588956
(Please avoid writing new tests using video-test.js) -->
<script src="video-test.js"></script>
<script>
function iframeLoad() {
var iframe = document.querySelector("iframe");
var iframeBody = iframe.contentDocument.querySelector("body");
// Required to be global for testExpected() to work properly.
iframeBodyStyle = iframe.contentDocument.defaultView.getComputedStyle(iframeBody, null);
testExpected("iframeBodyStyle.backgroundColor", "rgb(0, 0, 0)");
endTest();
}
function load() {
var iframe = document.querySelector("iframe");
iframe.onload = iframeLoad;
iframe.src = findMediaFile("video", "content/counting");
}
</script>
</head>
<body onload="load()">
<p>Test that video media documents have a black background.</p>
<iframe style="width: 200px; height: 200px;"></iframe>
</body>
</html>