Skip to content

Commit

Permalink
Bug 1073074: Browser chrome UI test output is broken. r=cmanchester
Browse files Browse the repository at this point in the history
  • Loading branch information
Mossop committed Sep 26, 2014
1 parent 5b24249 commit 90044df
Showing 1 changed file with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions testing/mochitest/browser-harness.xul
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,25 @@
}
var path = _entityEncode(this.path);
var html = this.results.map(function (t) {
var classname = t.info ? "info" : "result " + (t.pass ? "passed" : "failed");
var text = t.result + " | " + path + " | " + _entityEncode(t.msg);
var classname = "result ";
var result = "TEST-";
if (t.info) {
classname = "info";
result += "INFO";
}
else if (t.pass) {
classname += "passed";
if (t.todo)
result += "KNOWN-FAIL";
else
result += "PASS";
}
else {
classname += "failed";
result += "UNEXPECTED-" + t.status;
}
var message = t.name + (t.msg ? " - " + t.msg : "");
var text = result + " | " + path + " | " + _entityEncode(message);
if (!t.info && !t.pass) {
return '<p class="' + classname + '" id=\"ERROR' + (gErrorCount++) + '">' +
text + " <a href=\"javascript:scrollTo('ERROR" + gErrorCount + "')\">NEXT ERROR</a></p>";
Expand Down

0 comments on commit 90044df

Please sign in to comment.