dwf/rva: added JSONReporter

This commit is contained in:
pivotal
2008-12-04 10:56:58 -08:00
parent 735ebd6c66
commit cc164257a7
5 changed files with 130 additions and 63 deletions

17
lib/json_reporter.js Normal file
View File

@@ -0,0 +1,17 @@
JasmineReporters.JSON = function () {
var that = {
results: {},
addResults: function (results) {
that.results = results;
},
report: function () {
return Object.toJSON(that.results);
}
}
return that;
}
Jasmine.reporter = JasmineReporters.JSON();