Phalcon\Test\Unit\Tag\TagDateFieldTest::testDateFieldWithDisplayTo PHP Метод

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

Tests dateField with displayTo
С версии: 2014-09-05
Автор: Nikolaos Dimopoulos ([email protected])
    public function testDateFieldWithDisplayTo()
    {
        $this->specify("dateField with displayTo returns invalid HTML Strict", function () {
            $options = ['x_name', 'name' => 'x_other', 'class' => 'x_class', 'size' => '10'];
            $expected = '<input type="date" id="x_name" ' . 'name="x_other" value="x_value" class="x_class" ' . 'size="10"';
            $this->tester->testFieldParameter('dateField', $options, $expected, false, 'displayTo');
        });
        $this->specify("dateField with displayTo returns invalid HTML XHTML", function () {
            $options = ['x_name', 'name' => 'x_other', 'class' => 'x_class', 'size' => '10'];
            $expected = '<input type="date" id="x_name" ' . 'name="x_other" value="x_value" class="x_class" ' . 'size="10"';
            $this->tester->testFieldParameter('dateField', $options, $expected, true, 'displayTo');
        });
    }