Closed Bug 2052853 Opened 11 days ago Closed 5 days ago

[wpt-sync] Sync PR 61085 - HTML Processing Instruction tree format updates

Categories

(Testing :: web-platform-tests, task, P4)

task

Tracking

(firefox154 fixed)

RESOLVED FIXED
154 Branch
Tracking Status
firefox154 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 61085 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/61085
Details from upstream follow.

Jon Surrell <sirreal@users.noreply.github.com> wrote:

HTML Processing Instruction tree format updates

The specification for the tree construction HTML parser tests is out of data and the data files do not align with the specified format.

https://github.com/web-platform-tests/wpt/blob/5280c6aff8b08ed250962bf2695ac03e9c0c2bd1/html/syntax/parsing/resources/README.md?plain=1#L69-L72

  • Remove stale "The HTML parser cannot emit processing instructions…"
  • The data format specifies that the PI target is followed by a space. The tests and test.js are updated accordingly.
  • The README specified that the data is followed by >. This is updated to ?> according to the data that appears in the .dat files.

Further, I would consider aligning with the comment tree structure. Comments in the tree always open with <!-- and always close with -->. Comments start with the normative comment opener plus a space, and close with a space plus the normative comment closer. PI could adopt a similar format since the spec and the tests need to be updated for alignment. The tree format <?[[target]] [[data]] ?> would align with comments:

The proposed format would produce a serialized tree as follows:

input tree structure
<?target?> <?target ?>
<?target data?> <?target data ?>

This is a companion to #61083.

Whiteboard: [wptsync downstream] → [wptsync downstream error]
Whiteboard: [wptsync downstream error] → [wptsync downstream]

Test result changes from PR not available.

Status: NEW → RESOLVED
Closed: 5 days ago
Resolution: --- → FIXED
Target Milestone: --- → 154 Branch
You need to log in before you can comment on or make changes to this bug.