Esempio n. 1
0
 public function testInputBasics()
 {
     $f = new Form\Element\Text();
     $f->setValue('input-value');
     $f->setRequired(true);
     $f->setValidator(function ($value) {
         return $value == 'input-value';
     });
     $this->assertTrue($f->getValue() == 'input-value');
     $this->assertTrue($f->getRequired() == true);
     $this->assertTrue(is_callable($f->getValidator()));
 }