blob: e317186c3e646a9d1b7312713542cebc69ca10a6 [file] [log] [blame]
<!doctype html>
<html>
<head>
<title>audio events - readyState property during playing</title>
<script src="../../w3cwrapper.js"></script>
</head>
<body>
<p><a href="http://dev.w3.org/html5/spec/Overview.html#mediaevents">spec reference</a></p>
<audio id="a" autoplay controls>
</audio>
<div id="log"></div>
<script>
var t = async_test("audio.readyState should be >= HAVE_FUTURE_DATA during playing event", {timeout:30000});
var a = document.getElementById("a");
a.addEventListener("playing", function() {
t.step(function() {
assert_true(a.readyState >= a.HAVE_FUTURE_DATA);
});
t.done();
a.pause();
});
a.src = getAudioURI("http://media.w3.org/2010/05/sound/sound_5") + "?" + new Date() + Math.random();
</script>
</body>
</html>