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

Unified Diff: sky/benchmarks/resources/runner.sky

Issue 702603005: Add a sketch of a test_perf script (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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: sky/benchmarks/resources/runner.sky
diff --git a/sky/benchmarks/resources/runner.sky b/sky/benchmarks/resources/runner.sky
index e307c0d2732923a0eedfd0fc7814401ba5d0dc49..8497a612dbf0a72f7efe7806e27739704bcb6ffb 100644
--- a/sky/benchmarks/resources/runner.sky
+++ b/sky/benchmarks/resources/runner.sky
@@ -4,14 +4,14 @@ function PerfRunner(options) {
this.iterationsRemaining_ = options.iterations || 10;
this.results_ = [];
this.setup_ = options.setup;
+ this.logLines_ = [];
}
PerfRunner.prototype.log = function(line) {
- console.log(line);
+ this.logLines_.push(line);
};
PerfRunner.prototype.recordResult = function(result) {
- console.log(result);
this.results_.push(result);
};
@@ -82,6 +82,7 @@ PerfRunner.prototype.logStatistics = function(title) {
PerfRunner.prototype.finish = function () {
this.logStatistics("Time:");
+ internals.notifyTestComplete(this.logLines_.join('\n'));
}
module.exports = PerfRunner;

Powered by Google App Engine
This is Rietveld 408576698