[wp-trac] [WordPress Trac] #63527: Tests: Add test assertion to compare HTML for equivalence

WordPress Trac noreply at wordpress.org
Wed Jun 4 13:42:50 UTC 2025


#63527: Tests: Add test assertion to compare HTML for equivalence
-----------------------------+-----------------------------
 Reporter:  Bernhard Reiter  |      Owner:  (none)
     Type:  enhancement      |     Status:  new
 Priority:  normal           |  Milestone:  Awaiting Review
Component:  General          |    Version:
 Severity:  normal           |   Keywords:
  Focuses:                   |
-----------------------------+-----------------------------
 Comparing HTML markup can be error prone and fragile. Typically we're
 interested in ''semantically equivalent'' HTML; among other things, that
 means that the comparison should have built-in tolerance for different
 attribute and class name order.

 Ideally, the assertion should also produce output which is easily human-
 readable when flagging differences between two HTML strings.

 Finally, it should be able to understand block delimiters.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/63527>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list