Add execution time elapsed to JsApiReporter

Since this information is desired in ConsoleReporter, HtmlReporter,
and now JsApiReporter, the executionTime is passed through in
jasmineDone from Env instead of making each reporter compute it.

Fixes #30, [Finishes #45659879]
This commit is contained in:
Sheel Choksi
2013-06-09 12:05:03 -07:00
parent d5f1264416
commit ffdf1eb16d
11 changed files with 83 additions and 68 deletions

View File

@@ -11,8 +11,11 @@ getJasmineRequireObj().JsApiReporter = function() {
status = 'started';
};
this.jasmineDone = function() {
var executionTime;
this.jasmineDone = function(options) {
this.finished = true;
executionTime = options.executionTime;
status = 'done';
};
@@ -53,6 +56,10 @@ getJasmineRequireObj().JsApiReporter = function() {
return specs;
};
this.executionTime = function() {
return executionTime;
};
}
return JsApiReporter;