aboutsummaryrefslogtreecommitdiffstats
path: root/tests/phpunit/unit/includes/Html/HtmlHelperTest.php
Commit message (Collapse)AuthorAgeFilesLines
* Html,Xml: Widen `@covers` tagsTimo Tijhof2024-03-301-3/+3
| | | | | | | | | | | | | | | | | | | | > We lose useful coverage and waste valuable time on keeping tags > accurate through refactors (or worse, forget to do so). > > Tracking tiny per-method details wastes time in realizing (and > fixing) when people inevitably don't keep them in sync, and time > lost in finding uncovered code to write tests to realize it was > already covered but "not yet claimed". > > Given all used methods are de-facto and liberally claimed, and > that we keep the coverage limited to the subject class, this > maintains the spirit and intent. PHPUnit offers a more precise > tool when you need it (i.e. when testing legacy monster classes), > but for well-written code, the class-wide tag suffices. Ref https://gerrit.wikimedia.org/r/q/owner:Krinkle+is:merged+message:Widen Change-Id: I60151a0f5a811763fe326e92a18d3dcba8082761
* HtmlHelper: Fix entity encoding when $html5format = falseBartosz DziewoƄski2024-02-091-1/+1
| | | | | | | Follow-up to 84d0dff9680bed2aeaa491dfb5958634e0f27ec6. Bug: T354361 Change-Id: I44a98f667a89d0baa25188fc6d43f92b3ad19b84
* HtmlHelper: Add "legacy compatibility" modeC. Scott Ananian2023-12-111-0/+15
| | | | | | | | | | | | | When using HtmlHelper for style deduplication, slight differences in the serialization format used by the legacy parser caused test failures. Add a "compatibility" mode which tries to better match legacy parser behavior for void elements, character escapes, and other details. Parsoid HTML has always been serialized using an HTML5 serializer, so this compatibility mode will be disabled when processing Parsoid HTML. Change-Id: I0441aa3e44f6562e05e95a18cc282c53fe446788
* tests: Move test cases from /includes/ into sub folderUmherirrender2023-09-131-0/+44
Follow move of the tested class Most moves are part of T321882 Change-Id: I74ab45d6a5331dcb2ff0b65dc2cc7c6315146646