HomePhabricator

(stable) Fix some remarkup issues with selective construction of child nodes…

Description

(stable) Fix some remarkup issues with selective construction of child nodes after HTML DOM parsing

Summary:
See https://discourse.phabricator-community.org/t/bug-in-src-parser-html-phutildomnode-php/2882/.

The behavior of selectChildrenWithTags(...) currently isn't well-covered by tests and isn't quite right. Add coverage and fix it up.

Particularly, there's a bad call to a nonexistent method, and when we convert a tag that doesn't match the selection set into content, we incorrectly discard any paired closing tag.

Test Plan: Added failing tests, made them pass.

Reviewers: amckinley

Reviewed By: amckinley

Differential Revision: https://secure.phabricator.com/D20630

Details

Provenance
epriestleyAuthored on Jul 2 2019, 12:01 AM
epriestleyPushed on Jul 8 2019, 11:41 PM
Reviewer
amckinley
Differential Revision
D20630: Fix some remarkup issues with selective construction of child nodes after HTML DOM parsing
Parents
rPHUa4feaf52f4c0: (stable) Promote 2019 Week 26
Branches
Unknown
Tags
Unknown
Build Status
Buildable 23115
Build 31737: Run Core Tests