Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / plugins / release-frame-content-window.html
blobd40f51f32262d29a55bfead34d3c51cb65d67f5e
1 <!DOCTYPE html>
2 <html>
3 <script type="text/javascript">
4 if (window.testRunner) {
5 testRunner.dumpAsText();
6 testRunner.waitUntilDone();
10 function runTest() {
11 var p = document.getElementById('plg');
12 var iframe = document.getElementById('frame-id');
13 p.remember(iframe.contentWindow);
15 var someObject = {a: 1, b: 2};
16 // Load another page in iframe, so plugin keeps reference to old frame's contentWindow.
17 iframe.onload = function() {
18 // This will trigger Release Object for previously remembered reference.
19 p.remember(someObject);
20 document.getElementById('result').innerHTML = 'SUCCESS';
21 if (window.testRunner)
22 testRunner.notifyDone();
24 iframe.src = 'resources/empty2.html';
27 </script>
28 <body>
29 <embed id="plg" type="application/x-webkit-test-netscape"></embed><P>
30 <iframe id="frame-id" src="resources/empty.html" onload='runTest()'></iframe>
31 <div>This tests that releasing a reference to a contentWindow that has already been navigated away works correctly and does not crash. If this test is successful, the word SUCCESS should be seen below.</div>
32 <div id="result">FAILED</div>
33 </body>
34 </html>