Tue, 06 Jan 2015 21:39:09 +0100
Conditionally force memory storage according to privacy.thirdparty.isolate;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.
1 <!DOCTYPE HTML>
2 <html>
3 <head>
4 <title>Tests for for-of loops</title>
5 <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
6 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css">
7 </head>
8 <body onload="doTest()">
9 <p id="display"></p>
10 <div id="content" style="display: none"></div>
11 <script>
12 function doTest() {
13 // DOM NodeLists are iterable.
14 var a = [];
15 for (var e of document.body.childNodes)
16 if (e.nodeType === 1)
17 a.push(e.tagName);
18 is("P DIV SCRIPT", a.join(" "), "for-of should see each element in the body");
20 SimpleTest.finish();
21 }
22 SimpleTest.waitForExplicitFinish();
23 </script>
24 </body>
25 </html>