[wp-trac] [WordPress Trac] #64531: assertEqualHTML may ignore leading whitespace text
WordPress Trac
noreply at wordpress.org
Tue Jan 27 11:18:47 UTC 2026
#64531: assertEqualHTML may ignore leading whitespace text
-------------------------------------------------+-------------------------
Reporter: jonsurrell | Owner: jonsurrell
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 6.9.1
Component: Build/Test Tools | Version: 6.9
Severity: normal | Resolution: fixed
Keywords: has-patch has-unit-tests dev- | Focuses:
feedback fixed-major |
-------------------------------------------------+-------------------------
Changes (by jonsurrell):
* status: reopened => closed
* resolution: => fixed
Comment:
In [changeset:"61536" 61536]:
{{{
#!CommitTicketReference repository="" revision="61536"
Build/Test Tools: Ensure `assertEqualHTML()` recognizes whitespace text.
Ensure whitespace text nodes are correctly represented by
`build_visual_html_tree()`.
The `build_visual_html_tree()` function used by `assertEqualHTML()` would
remove some leading whitespace from text nodes. Some whitespace-only text
nodes were omitted from the tree.
Developed in https://github.com/WordPress/wordpress-develop/pull/10765.
Follow-up to [60295].
Reviewed by wildworks.
Merges [61519] to the 6.9 branch.
Props jonsurrell, dmsnell, bernhard-reiter.
Fixes #64531.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64531#comment:24>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list