Phalcon\Test\Unit\Tag\TagWeekFieldTest::testWeekFieldWithSetDefaultElementNotPresent PHP 메소드

testWeekFieldWithSetDefaultElementNotPresent() 공개 메소드

Tests weekField with setDefault and element not present
부터: 2014-09-05
저자: Nikolaos Dimopoulos ([email protected])
    public function testWeekFieldWithSetDefaultElementNotPresent()
    {
        $this->specify("weekField 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="week" id="x_name" ' . 'name="x_other" value="x_value" class="x_class" ' . 'size="10"';
            $this->tester->testFieldParameter('weekField', $options, $expected, false, 'setDefault');
        });
        $this->specify("weekField 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="week" id="x_name" ' . 'name="x_other" value="x_value" class="x_class" ' . 'size="10"';
            $this->tester->testFieldParameter('weekField', $options, $expected, true, 'setDefault');
        });
    }