1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-06 14:16:32 +02:00

[3.0.0] Add global scoping support for ExtractStyleBlocks; scoped="" attribute bumped off for some 'other' time.

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@1478 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang
2008-01-05 19:19:55 +00:00
parent a7fab00cdd
commit 8779b46fc4
6 changed files with 182 additions and 28 deletions

View File

@@ -39,6 +39,13 @@ class HTMLPurifier_Harness extends UnitTestCase
return array(HTMLPurifier_Config::createDefault(), new HTMLPurifier_Context);
}
/**
* Normalizes a string to Unix (\n) endings
*/
function normalize(&$string) {
$string = str_replace(array("\r\n", "\r"), "\n", $string);
}
/**
* If $expect is false, ignore $result and check if status failed.
* Otherwise, check if $status if true and $result === $expect.