Bug 1522246 - Fix browser_test_performance_metrics.js test, r=tarek.

--HG--
rename : dom/tests/browser/shared_worker.js => dom/tests/browser/perfmetrics/shared_worker.js
extra : rebase_source : f9f6b44886fffe48bddcb1907213e04a24718b55
This commit is contained in:
Brian Hackett 2019-02-28 11:52:12 -10:00
Родитель 3d0e2d8ec9
Коммит 96cb980e63
4 изменённых файлов: 3 добавлений и 4 удалений

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

@ -10,6 +10,7 @@ support-files =
ping_worker.js
setinterval.html
settimeout.html
shared_worker.js
unresponsive.html
hello.ogg
sound.html

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

@ -138,9 +138,7 @@ add_task(async function test() {
Assert.ok(isTopLevel, "example.com as a top level window");
Assert.ok(aboutMemoryFound, "about:memory");
Assert.ok(heapUsage > 0, "got some memory value reported");
// FIXME bug 1522246. the worker performance improvements in this bug cause
// the shared worker to shut down too quickly to report any info.
// Assert.ok(sharedWorker, "We got some info from a shared worker");
Assert.ok(sharedWorker, "We got some info from a shared worker");
let numCounters = counterIds.length;
Assert.ok(numCounters > 5, "This test generated at least " + numCounters + " unique counters");

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

@ -9,7 +9,7 @@
function init() {
shared = new SharedWorker("shared_worker.js");
shared.port.start();
for (let i = 0; i++; i < 10) shared.port.postMessage(["ok"]);
for (let i = 0; i < 10; i++) shared.port.postMessage(["ok"]);
}
</script>