зеркало из https://github.com/mozilla/gecko-dev.git
Bug 503363 - include filename+linenumber for exceptions thrown during mochitest. r=sdwilsh
This commit is contained in:
Родитель
62457ae242
Коммит
04ced9b45b
|
@ -152,8 +152,13 @@ function testResult(aCondition, aName, aDiag, aIsTodo) {
|
|||
else
|
||||
this.result = "TEST-PASS";
|
||||
} else {
|
||||
if (aDiag)
|
||||
if (aDiag) {
|
||||
if (typeof aDiag == "object" && "fileName" in aDiag) {
|
||||
// we have an exception - print filename and linenumber information
|
||||
this.msg += " at " + aDiag.fileName + ":" + aDiag.lineNumber;
|
||||
}
|
||||
this.msg += " - " + aDiag;
|
||||
}
|
||||
if (aIsTodo)
|
||||
this.result = "TEST-UNEXPECTED-PASS";
|
||||
else
|
||||
|
|
Загрузка…
Ссылка в новой задаче