public function testFilter()
{
$fields = array('username' => array('type' => 'text', 'value' => 'Username here...', 'label' => 'Username:'******'required' => true, 'attributes' => array('size' => 40)));
$f = new Form('/submit', 'post', $fields);
$f->setFieldValues(array('username' => '<p>te\'st"<script>user</script></p>'), array('strip_tags' => '<p>', 'htmlentities' => array(ENT_QUOTES, 'UTF-8')));
$this->assertEquals('<p>te'st"user</p>', $f->username);
$f->filter(array('html_entity_decode' => array(ENT_QUOTES, 'UTF-8')));
$this->assertEquals('<p>te\'st"user</p>', $f->username);
}