New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 664992 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Last visit > 30 days ago
Closed: Dec 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 441355



Sign in to add a comment

http/tests/inspector/resource-tree/resource-tree-frame-navigate.html isn't robust

Project Member Reported by tkent@chromium.org, Nov 14 2016

Issue description

The test has the following code:

function navigateIframe()
{
    var iframe = document.getElementById("iframe");
    iframe.setAttribute("src", "resources/resource-tree-frame-navigate-iframe-after.html");
    document.body.appendChild(iframe);
}


* If we replace document.body.appendChild(iframe) with:
  document.body.removeChild(iframe);
  document.body.appendChild(iframe);,
We'll see resource-tree-frame-navigate-iframe-before.html and its sub-resources in "After navigation" section" of the result.
If we fix  Issue 441355 , the appendChild() would work so.

In the real DevTools, such resources are correctly removed. I think this is a test harness issue.

* Furthermore, document.body.appendChild(iframe) is unnecessary in this test at all.  Updating 'src' attribute is enough to trigger IFRAME loading.

 

Comment 1 by l...@chromium.org, Nov 14 2016

Owner: chenwilliam@chromium.org

Comment 2 by l...@chromium.org, Nov 14 2016

@chenwilliam this test is not yours, but maybe we can update this test and all instances where we appendChild(iframe) in this way?
Project Member

Comment 3 by bugdroid1@chromium.org, Feb 8 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1c12127b721f833f37b81553e19b8eb0392da651

commit 1c12127b721f833f37b81553e19b8eb0392da651
Author: tkent <tkent@chromium.org>
Date: Wed Feb 08 07:22:24 2017

DOM: Remove standard-violating optimizations in appendChild, insertBefore, and replaceChild.

These functions did nothing in some cases; e.g. node.appendChild(node.lastChild).
However, it violates the DOM standard, and is not interoperable.

This CL removes the optimizations, and fixes a timeout in MutationObserver-
childList.html.  However, the test still fails because of another issue.

The new behavior matches to Firefox and Safari.

Test changes:
* http/tests/inspector/resource-tree/resource-tree-frame-navigate.html
  appendChild() confuses the test. It's just unnecessary. See  crbug.com/664992 .

* plugins/reattach-plugin-during-access.html
 divElem.appendChild(objElem) was executed repeatedly. Once is enough.

* paint/invalidation/svg/tabgroup.svg
  We have more paint due to the removal of the optimization.

BUG= 441355 ,  664992 

Review-Url: https://codereview.chromium.org/2496133002
Cr-Commit-Position: refs/heads/master@{#448928}

[modify] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/LayoutTests/TestExpectations
[add] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/LayoutTests/external/wpt/dom/nodes/MutationObserver-childList-expected.txt
[modify] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/LayoutTests/external/wpt/dom/nodes/Node-replaceChild-expected.txt
[delete] https://crrev.com/a79a95466df9d013721167cf2f0c8ba849214207/third_party/WebKit/LayoutTests/external/wpt/dom/ranges/Range-mutations-appendChild-expected.txt
[delete] https://crrev.com/a79a95466df9d013721167cf2f0c8ba849214207/third_party/WebKit/LayoutTests/external/wpt/dom/ranges/Range-mutations-insertBefore-expected.txt
[delete] https://crrev.com/a79a95466df9d013721167cf2f0c8ba849214207/third_party/WebKit/LayoutTests/external/wpt/dom/ranges/Range-mutations-replaceChild-expected.txt
[modify] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/LayoutTests/http/tests/inspector/resource-tree/resource-tree-frame-navigate.html
[modify] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/LayoutTests/plugins/reattach-plugin-during-access.html
[modify] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/Source/core/dom/ContainerNode.cpp
[modify] https://crrev.com/1c12127b721f833f37b81553e19b8eb0392da651/third_party/WebKit/Source/core/dom/Range.cpp

Sign in to add a comment