public testCanAddRequiredTextToPlainFieldsAsArray ( ) |
public function testCanAddRequiredTextToPlainFieldsAsArray()
{
$this->former->close();
$this->former->withRules(array('foo' => array('required')));
$input = $this->former->text('foo')->__toString();
$label = $this->matchLabel('Foo', 'foo', true);
unset($label['attributes']['class']);
$this->assertHTML($this->matchField(array('required' => 'true')), $input);
$this->assertHTML($label, $input);
}