OLD | NEW |
(Empty) | |
| 1 <!DOCTYPE html> |
| 2 <html> |
| 3 <head> |
| 4 <script> |
| 5 function runTest() |
| 6 { |
| 7 if (window.testRunner) { |
| 8 testRunner.dumpAsText(); |
| 9 testRunner.dumpChildFramesAsText(); |
| 10 } |
| 11 body = document.getElementById('body'); |
| 12 frame1 = document.getElementById('frame1'); |
| 13 body.removeChild(frame1); |
| 14 |
| 15 // Below we effectively execute (pseudo-code): |
| 16 // window.name = "same name as before" |
| 17 // This shouldn't trigger a recalculation of unique name (which can result |
| 18 // in a different unique name, because right now there is no frame1 with |
| 19 // a conflicting window.name=="foo"). |
| 20 frame2 = document.getElementById('frame2'); |
| 21 frame2.contentWindow.name = "foo"; |
| 22 |
| 23 // Before fixes, this test used to trigger a DCHECK in |
| 24 // void FrameTreeNode::SetFrameName(...) { |
| 25 // if (name == replication_state_.name) { |
| 26 // // |unique_name| shouldn't change unless |name| changes. |
| 27 // DCHECK_EQ(unique_name, replication_state_.unique_name); |
| 28 // return; |
| 29 // } |
| 30 } |
| 31 </script> |
| 32 </head> |
| 33 <body onload="runTest()" id="body"> |
| 34 <iframe name="foo" id="frame1"></iframe> |
| 35 <iframe name="foo" id="frame2"></iframe> |
| 36 </body> |
| 37 </html> |
OLD | NEW |