1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-08-11 00:24:03 +02:00

Augment URISchemeRegistry with the ability to overload/register your own schemes.

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@215 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang
2006-08-12 17:06:14 +00:00
parent 10ea44932a
commit 6c3d364213
5 changed files with 35 additions and 10 deletions

View File

@@ -10,9 +10,9 @@ class HTMLPurifier_AttrDefHarness extends UnitTestCase
// cannot be used for accumulator
function assertDef($string, $expect = true, $message = '%s') {
// $expect can be a string or bool
$this->setUpAssertDef();
if (!$this->config) $this->config = HTMLPurifier_Config::createDefault();
if (!$this->context) $this->context = new HTMLPurifier_AttrContext();
$this->setUpAssertDef();
$result = $this->def->validate($string, $this->config, $this->context);
if ($expect === true) {
$this->assertIdentical($string, $result, $message);