lithium\tests\cases\template\helper\FormTest::testFieldTemplateOverride PHP Method

testFieldTemplateOverride() public method

Tests that the string template form Form::field() can be overridden.
    public function testFieldTemplateOverride()
    {
        $this->form->config(array('templates' => array('field' => '{:label}{:input}{:error}')));
        $result = $this->form->field('name', array('type' => 'text'));
        $this->assertTags($result, array('label' => array('for' => 'Name'), 'Name', '/label', 'input' => array('type' => 'text', 'name' => 'name', 'id' => 'Name')));
    }
FormTest