Пример #1
0
    /**
     * testExtensionProvider
     *
     * @return  void
     */
    public function testExtensionProvider()
    {
        $this->controller->getInput()->set('paths', array('extension'));
        $compare = <<<HTML
Hello, sakura
HTML;
        $this->assertStringDataEquals($compare, $this->controller->execute());
    }
Пример #2
0
    /**
     * testMarkdown
     *
     * @return  void
     */
    public function testMarkdown()
    {
        $this->controller->getInput()->set('paths', array('flower', 'markdown'));
        $compare = <<<HTML
<h1>Test Heading</h1>
<p>This is paragraph</p>
<p><a href="foo.html">This is link</a></p>
HTML;
        $this->assertStringDataEquals($compare, $this->controller->execute());
    }
Пример #3
0
    public function testWithLayout()
    {
        $this->controller->getInput()->set('paths', array('olive', 'layout'));
        $compare = <<<HTML
<p>
\t<h2>Hello World</h2>
\t<p>test data</p>
\t<p><img src="img.jpg" alt="img" /></p>
</p>
HTML;
        $this->assertStringDataEquals($compare, $this->controller->execute());
    }
Пример #4
0
    /**
     * testPermalinkIndex
     *
     * @return  void
     */
    public function testParentLayout()
    {
        $this->controller->getInput()->set('paths', array('flower', 'index'));
        $compare = <<<HTML
<p>
\tFile: flower/index
\turi.base: ../
\turi.media: ../media/
</p>
HTML;
        $this->assertStringDataEquals($compare, $this->controller->execute());
    }