New issue
Advanced search Search tips

Issue 700266 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Mar 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

Range.surroundContents() should not check childTypeAllowed

Project Member Reported by tkent@chromium.org, Mar 10 2017

Issue description

Chrome Version: 59 Canary
OS: All but iOS

What steps will reproduce the problem?
(1) Open http://w3c-test.org/dom/ranges/Range-surroundContents.html

What is the expected result?
No FAILs

What happens instead?
There are multiple FAIL about |processingInstruction|.
e.g. 37,0 - 37,15

The root cause of failures is our code has redundant check not defined in the DOM specification.

Safari and Firefox passes these tests.

 
Project Member

Comment 1 by bugdroid1@chromium.org, Mar 10 2017

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

commit caf3c3acbe69ac013e2aaafad5c8110bb66e435a
Author: tkent <tkent@chromium.org>
Date: Fri Mar 10 07:27:13 2017

Range.surroundContents() should not check node types beforehand.

Our implementation checked childTypeAllowed() beforehand.  However, this is not
defined by the DOM standard, and caused some test failures. This CL removes it.

Also, this CL corrects the order of step 3 and step 4 because the above removal
regressed some passing tests, and the order correction recovers them.

BUG= 700266 

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

[modify] https://crrev.com/caf3c3acbe69ac013e2aaafad5c8110bb66e435a/third_party/WebKit/LayoutTests/external/wpt/dom/ranges/Range-surroundContents-expected.txt
[modify] https://crrev.com/caf3c3acbe69ac013e2aaafad5c8110bb66e435a/third_party/WebKit/Source/core/dom/Range.cpp

Comment 2 by tkent@chromium.org, Mar 10 2017

Labels: M-59
Status: Fixed (was: Started)

Sign in to add a comment