Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Setting outerHTML on child of DocumentFragment should not throw error
https://bugs.webkit.org/show_bug.cgi?id=249737 rdar://problem/103746193 Reviewed by Chris Dumez. This patch aligns WebKit with Gecko / Firefox and Web-Spec [1]. In 238774@main, WebKit aligned with behavior for better compatibility but it was not correct and clarified later to not throw error [2]. This PR is essentially revert part of 238774@main with update to align by not throwing error. [1] https://w3c.github.io/DOM-Parsing/#dom-element-outerhtml [2] whatwg/html#8657 * Source/WebCore/dom/Element.cpp: (Element::setOuterHTML): Update to not throw error * LayoutTests/fast/dynamic/outerHTML-no-element.html: Rebaselined * LayoutTests/fast/dynamic/outerHTML-no-element-expected.txt: Rebaselined * LayoutTests/fast/dom/set-outer-html-special-cases.html: Rebaselined * LayoutTests/fast/dom/set-outer-html-special-cases-expected.txt: Rebaselined Canonical link: https://commits.webkit.org/266086@main
- Loading branch information
1 parent
3a311fd
commit b41af45
Showing
5 changed files
with
9 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
test for 4110775 Crash will occur when double-clicking outerHTML link on W3 DOM test | ||
|
||
If the test fails, Safari may crash, or you may see a failure message below. If the test passes, you should see a message with a description of the expected exception. | ||
If the test fails, Safari may crash, or you may see a failure message below. If the test passes, you should see "This test passed!". | ||
|
||
This test passed - expected error - NoModificationAllowedError: Cannot set outerHTML on element because it doesn't have a parent | ||
This test passed! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters