MediaWiki
1.33.0
|
Static Public Member Functions | |
static | normalize ( $text, $funcs) |
Public Attributes | |
$invalid | |
$xpath | |
Protected Member Functions | |
__construct ( $text) | |
removeTbody () | |
serialize () | |
Serialize the XML DOM for comparison purposes. More... | |
trimWhitespace () | |
The point of this function is to produce a normalized DOM in which Tidy's output matches the output of RemexHtml. More... | |
Protected Attributes | |
$doc | |
Definition at line 7 of file ParserTestResultNormalizer.php.
|
protected |
Definition at line 21 of file ParserTestResultNormalizer.php.
|
static |
Definition at line 10 of file ParserTestResultNormalizer.php.
References as.
|
protected |
Definition at line 37 of file ParserTestResultNormalizer.php.
References as.
|
protected |
Serialize the XML DOM for comparison purposes.
This does not generate HTML.
Definition at line 83 of file ParserTestResultNormalizer.php.
|
protected |
The point of this function is to produce a normalized DOM in which Tidy's output matches the output of RemexHtml.
Tidy both trims and pretty-prints, so this requires fairly aggressive treatment.
In particular, note that Tidy converts
x
to
\nx\n
, which theoretically affects display since the second line break is not ignored by compliant HTML parsers.
This function also removes empty elements, as does Tidy.
Definition at line 59 of file ParserTestResultNormalizer.php.
References as.
|
protected |
Definition at line 8 of file ParserTestResultNormalizer.php.
ParserTestResultNormalizer::$invalid |
Definition at line 8 of file ParserTestResultNormalizer.php.
ParserTestResultNormalizer::$xpath |
Definition at line 8 of file ParserTestResultNormalizer.php.