PSR-2 reformatting PHPDoc corrections
[htmlpurifier.git] / tests / HTMLPurifier / AttrDef / HTML / NmtokensTest.php
blobd466146e467300c6136e0107ef33ecd29de3b87c
1 <?php
3 class HTMLPurifier_AttrDef_HTML_NmtokensTest extends HTMLPurifier_AttrDefHarness
6 public function setUp()
8 parent::setUp();
9 $this->def = new HTMLPurifier_AttrDef_HTML_Nmtokens();
12 public function testDefault()
14 $this->assertDef('valid');
15 $this->assertDef('a0-_');
16 $this->assertDef('-valid');
17 $this->assertDef('_valid');
18 $this->assertDef('double valid');
20 $this->assertDef('0invalid', false);
21 $this->assertDef('-0', false);
23 // test conditional replacement
24 $this->assertDef('validassoc 0invalid', 'validassoc');
26 // test whitespace leniency
27 $this->assertDef(" double\nvalid\r", 'double valid');
29 // test case sensitivity
30 $this->assertDef('VALID');
36 // vim: et sw=4 sts=4