Bug 1361054 - use registerCleanup in scratchpad browser tests;r=ochameau

AFAICT SimpleTest.registerCleanup is never called here. And it introduced a leak
in the session scratchpad test I want to move to this test suite. I couldn't really
understand where the leak was coming from, but using registerCleanup (which _is_
called) fixes it.

MozReview-Commit-ID: 2VE7wHxy066

--HG--
extra : rebase_source : b2e7f62a727535912be55c68d6f8b0932e9f1414
This commit is contained in:
Julian Descottes 2017-05-08 12:25:47 +02:00
Родитель 11d4740f39
Коммит 98b89c91bc
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -18,7 +18,7 @@ const promise = require("promise");
var gScratchpadWindow; // Reference to the Scratchpad chrome window object var gScratchpadWindow; // Reference to the Scratchpad chrome window object
flags.testing = true; flags.testing = true;
SimpleTest.registerCleanupFunction(() => { registerCleanupFunction(() => {
flags.testing = false; flags.testing = false;
}); });