Bug 1059381 - Implement SimpleTest.requestCompleteLog for mochitest browser. r=jmaher

This commit is contained in:
Chris Manchester 2014-09-03 11:25:18 -04:00
parent c197954a8c
commit d7015095cb
2 changed files with 9 additions and 1 deletions

View File

@ -25,7 +25,7 @@ XPCOMUtils.defineLazyModuleGetter(this, "ContentSearch",
"resource:///modules/ContentSearch.jsm");
const SIMPLETEST_OVERRIDES =
["ok", "is", "isnot", "ise", "todo", "todo_is", "todo_isnot", "info", "expectAssertions"];
["ok", "is", "isnot", "ise", "todo", "todo_is", "todo_isnot", "info", "expectAssertions", "requestCompleteLog"];
window.addEventListener("load", function testOnLoad() {
window.removeEventListener("load", testOnLoad);
@ -908,6 +908,13 @@ function testScope(aTester, aTest) {
});
}
};
this.requestCompleteLog = function test_requestCompleteLog() {
self.__tester.dumper.structuredLogger.deactivateBuffering();
self.registerCleanupFunction(function() {
self.__tester.dumper.structuredLogger.activateBuffering();
})
};
}
testScope.prototype = {
__done: true,

View File

@ -1,4 +1,5 @@
function test() {
SimpleTest.requestCompleteLog();
ok(true, "pass ok");
is(true, true, "pass is");
isnot(false, true, "pass isnot");