chromium/third_party/blink/web_tests/fast/dom/insertedIntoDocument-iframe.html

<html>
<head>
<script>
if (window.testRunner) {
    testRunner.dumpAsText();
    testRunner.waitUntilDone();
}

gc = window.gc || function()
{
    if (window.GCController)
        return GCController.collect();
    
    for (var i = 0; i < 10000; ++i)
        var s = new String("AAAA");
}

window.onload = function()
{
    parent = document.createElement("div");
    parent.innerHTML = "<iframe></iframe><element id='element'/>";

    iframe = parent.firstChild;
    iframe.src = "javascript:top.document.body.removeChild(top.parent); top.parent = top.iframe = null; top.gc()";
    
    document.body.appendChild(parent);
    setTimeout(finishTest, 0);
}

finishTest = function()
{
    document.getElementById("element");
    
    if (window.testRunner)
        testRunner.notifyDone();
}
</script>
</head>
<body>PASS</body>
</html>