3 class HTMLPurifier_AttrTransform_InputTest
extends HTMLPurifier_AttrTransformHarness
6 public function setUp()
9 $this->obj
= new HTMLPurifier_AttrTransform_Input();
12 public function testEmptyInput()
14 $this->assertResult(array());
17 public function testInvalidCheckedWithEmpty()
19 $this->assertResult(array('checked' => 'checked'), array());
22 public function testInvalidCheckedWithPassword()
24 $this->assertResult(array(
25 'checked' => 'checked',
32 public function testValidCheckedWithUcCheckbox()
34 $this->assertResult(array(
35 'checked' => 'checked',
41 public function testInvalidMaxlength()
43 $this->assertResult(array(
53 public function testValidMaxLength()
55 $this->assertResult(array(
60 // these two are really bad test-cases
62 public function testSizeWithCheckbox()
64 $this->assertResult(array(
75 public function testSizeWithText()
77 $this->assertResult(array(
79 'size' => '100px', // spurious value, to indicate no validation takes place
86 public function testInvalidSrc()
88 $this->assertResult(array(
93 public function testMissingValue()
95 $this->assertResult(array(
105 // vim: et sw=4 sts=4