Example #1
0
 /**
  * @group ZF-3499
  */
 public function testHelperAttributeShouldNotBePresentInFieldsetTag()
 {
     $form = new Form();
     $form->setAction('/foo/bar')
          ->setMethod('post')
          ->setAttrib('helper', 'form')
          ->setView($this->getView());
     $this->decorator->setElement($form);
     $test = $this->decorator->render('content');
     $this->assertContains('<fieldset', $test, $test);
     $this->assertNotContains('helper="', $test);
 }
Example #2
0
 /**
  * @group ZF2-104
  */
 public function testFieldSetOptionsShouldOverrideElementAttribs()
 {
     $form = new Form();
     $form->setAction('/foo/bar')->setMethod('post')->setView($this->getView());
     $this->decorator->setElement($form);
     $form->setAttrib('class', 'someclass');
     $this->assertEquals('someclass', $this->decorator->getOption('class'));
     $this->decorator->setOption('class', 'otherclass');
     $this->assertEquals('otherclass', $this->decorator->getOption('class'));
 }