Release 2.0.1, merged in 1181 to HEAD.
[htmlpurifier.git] / tests / HTMLPurifier / ChildDef / OptionalTest.php
blobbdb5ac05260ffc33f6442b05c3c430cddbb43a56
1 <?php
3 require_once 'HTMLPurifier/ChildDefHarness.php';
4 require_once 'HTMLPurifier/ChildDef/Optional.php';
6 class HTMLPurifier_ChildDef_OptionalTest extends HTMLPurifier_ChildDefHarness
9 function test() {
11 $this->obj = new HTMLPurifier_ChildDef_Optional('b | i');
13 $this->assertResult('<b>Bold text</b><img />', '<b>Bold text</b>');
14 $this->assertResult('Not allowed text', '');