OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <html> |
| 3 <head> |
| 4 <meta charset="utf-8"> |
| 5 <script src="../resources/js-test.js"></script> |
| 6 <script src="../resources/gc.js"></script> |
| 7 </head> |
| 8 <body> |
| 9 <script> |
| 10 |
| 11 description("Test that window.crypto wrapper preserves custom properties."); |
| 12 jsTestIsAsync = true; |
| 13 |
| 14 function startTest() |
| 15 { |
| 16 window.crypto.foo = "bar"; |
| 17 gc(); |
| 18 setTimeout(continueTest, 10); |
| 19 } |
| 20 |
| 21 function continueTest() |
| 22 { |
| 23 gc(); |
| 24 setTimeout(finishTest, 10); |
| 25 } |
| 26 |
| 27 function finishTest() |
| 28 { |
| 29 gc(); |
| 30 shouldBe('window.crypto.foo', '"bar"'); |
| 31 finishJSTest(); |
| 32 } |
| 33 |
| 34 window.onload = startTest; |
| 35 |
| 36 </script> |
| 37 </body> |
| 38 </html> |
OLD | NEW |