blob: 099493b0b4f72e7762556f8f0f1834ff922ed4c4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
"use strict";
const PAGE_URL =
"http://example.com/browser/dom/tests/browser/page_bytecode_cache_asm_js.html";
add_task(async function() {
// Eagerly generate bytecode cache.
await SpecialPowers.pushPrefEnv({
set: [
["dom.script_loader.bytecode_cache.enabled", true],
["dom.script_loader.bytecode_cache.strategy", -1],
],
});
await BrowserTestUtils.withNewTab(
{
gBrowser,
url: PAGE_URL,
waitForLoad: true,
},
async browser => {
let result = await SpecialPowers.spawn(browser, [], () => {
return content.document.getElementById("result").textContent;
});
// No error shoud be caught by content.
is(result, "ok");
}
);
await SpecialPowers.popPrefEnv();
});
|