3 class HTMLPurifier_ChildDef_OptionalTest
extends HTMLPurifier_ChildDefHarness
8 $this->obj
= new HTMLPurifier_ChildDef_Optional('b | i');
11 function testBasicUsage() {
12 $this->assertResult('<b>Bold text</b><img />', '<b>Bold text</b>');
15 function testRemoveForbiddenText() {
16 $this->assertResult('Not allowed text', '');
19 function testEmpty() {
20 $this->assertResult('');
23 function testWhitespace() {
24 $this->assertResult(' ');
27 function testMultipleWhitespace() {
28 $this->assertResult(' ');