OLD | NEW |
(Empty) | |
| 1 <!-- Used by media_cpu_perf to calculate CPU performance statistics. --> |
| 2 |
| 3 <!DOCTYPE html> |
| 4 <html lang="en-US"> |
| 5 <head> |
| 6 <title>CPU and Memory Perf Test</title> |
| 7 </head> |
| 8 |
| 9 <body> |
| 10 <video preload controls></video> |
| 11 </body> |
| 12 |
| 13 <script type="text/javascript"> |
| 14 var video = document.querySelector("video"); |
| 15 |
| 16 video.addEventListener("error", function() { endTest(false); }, false); |
| 17 video.addEventListener("ended", function() { endTest(true); }, false); |
| 18 |
| 19 function endTest(successFlag) { |
| 20 // Notify PyAuto that we've completed the test run. |
| 21 if (window.domAutomationController) |
| 22 window.domAutomationController.send(successFlag); |
| 23 } |
| 24 |
| 25 function startTest(url) { |
| 26 video.src = url; |
| 27 video.play(); |
| 28 } |
| 29 </script> |
| 30 </html> |
OLD | NEW |