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

Unified Diff: chrome/test/data/media/html/media_cpu_perf.html

Issue 9464004: Fix CPU and memory perf PyAuto test running on av_perf. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/media/html/media_cpu_perf.html
diff --git a/chrome/test/data/media/html/media_cpu_perf.html b/chrome/test/data/media/html/media_cpu_perf.html
new file mode 100644
index 0000000000000000000000000000000000000000..89111863ceb416fba300997750e413e0f86cb58a
--- /dev/null
+++ b/chrome/test/data/media/html/media_cpu_perf.html
@@ -0,0 +1,30 @@
+<!-- Used by media_cpu_perf to calculate CPU performance statistics. -->
+
+<!DOCTYPE html>
+<html lang="en-US">
+ <head>
+ <title>CPU and Memory Perf Test</title>
+ </head>
+
+ <body>
+ <video preload controls></video>
+ </body>
+
+ <script type="text/javascript">
+ var video = document.querySelector("video");
+
+ video.addEventListener("error", function() { endTest(false); }, false);
+ video.addEventListener("ended", function() { endTest(true); }, false);
+
+ function endTest(successFlag) {
+ // Notify PyAuto that we've completed the test run.
+ if (window.domAutomationController)
+ window.domAutomationController.send(successFlag);
+ }
+
+ function startTest(url) {
+ video.src = url;
+ video.play();
+ }
+ </script>
+</html>
« no previous file with comments | « no previous file | chrome/test/functional/media/media_cpu_perf.py » ('j') | chrome/test/functional/media/media_cpu_perf.py » ('J')

Powered by Google App Engine
This is Rietveld 408576698