Phalcon\Test\Unit\Tag\TagStylesheetlinkTest::testStylesheetLinkStringParameterLocal PHP Метод

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

Tests stylesheetLink with string parameter for a local link
С версии: 2014-09-12
Автор: Nikolaos Dimopoulos ([email protected])
Автор: Dreamszhu ([email protected])
    public function testStylesheetLinkStringParameterLocal()
    {
        $this->specify("stylesheetLink with string parameter local returns invalid HTML Strict", function () {
            Tag::resetInput();
            $options = 'css/phalcon.css';
            $expected = '<link rel="stylesheet" type="text/css" ' . 'href="/css/phalcon.css" />' . PHP_EOL;
            Tag::setDocType(Tag::XHTML10_STRICT);
            $actual = Tag::stylesheetLink($options);
            expect($actual)->equals($expected);
        });
        $this->specify("stylesheetLink with string parameter local returns invalid HTML HTML5", function () {
            Tag::resetInput();
            $options = 'css/phalcon.css';
            $expected = '<link rel="stylesheet" type="text/css" ' . 'href="/css/phalcon.css">' . PHP_EOL;
            Tag::setDocType(Tag::HTML5);
            $actual = Tag::stylesheetLink($options);
            expect($actual)->equals($expected);
        });
    }