Phalcon\Test\Unit\Tag\TagMonthFieldTest::testMonthFieldWithSetDefaultElementNotPresent PHP Метод

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

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