FluidTYPO3\Flux\Tests\Unit\FormTest::canGetLabelFromVariousObjectsInsideForm PHP Метод

canGetLabelFromVariousObjectsInsideForm() публичный Метод

    public function canGetLabelFromVariousObjectsInsideForm()
    {
        $form = $this->getEmptyDummyForm();
        $field = $form->createField('Input', 'test');
        $objectField = $form->createField('Input', 'objectField');
        $form->add($field);
        $section = $form->createContainer('Section', 'section');
        $object = $form->createContainer('Object', 'object');
        $object->add($objectField);
        $section->add($object);
        $form->add($section);
        $this->assertInstanceOf('FluidTYPO3\\Flux\\Form', $object->getRoot());
        $this->assertNotEmpty($form->get('options')->getLabel());
        $this->assertNotEmpty($form->get('test', TRUE)->getLabel());
        $this->assertNotEmpty($form->get('object', TRUE)->getLabel());
        $this->assertNotEmpty($form->get('objectField', TRUE)->getLabel());
    }