1
0
mirror of https://github.com/ezyang/htmlpurifier.git synced 2025-07-31 19:30:21 +02:00

[1.5.0] Add support for IDREF

git-svn-id: http://htmlpurifier.org/svnroot/htmlpurifier/trunk@703 48356398-32a2-884e-a903-53898d9a118a
This commit is contained in:
Edward Z. Yang
2007-02-02 22:03:09 +00:00
parent e1a5d10e75
commit bda2615b30
3 changed files with 39 additions and 3 deletions

View File

@@ -74,6 +74,25 @@ class HTMLPurifier_AttrDef_IDTest extends HTMLPurifier_AttrDefHarness
}
function testIDReference() {
$this->def = new HTMLPurifier_AttrDef_ID(true);
$this->assertDef('good_id');
$this->assertDef('good_id'); // duplicates okay
$this->assertDef('<b>', false);
$this->def = new HTMLPurifier_AttrDef_ID();
$this->assertDef('good_id');
$this->assertDef('good_id', false); // duplicate now not okay
$this->def = new HTMLPurifier_AttrDef_ID(true);
$this->assertDef('good_id'); // reference still okay
}
}
?>