Example #1
0
 public function testLabelIsTranslatedWhenTranslationAvailable()
 {
     $translations = array('Label' => 'This is the Submit Label');
     $translate = new Translator('ArrayAdapter', $translations);
     $submit = new SubmitElement('foo', 'Label');
     $submit->setTranslator($translate);
     $this->assertEquals($translations['Label'], $submit->getLabel());
 }