Commit 2194e6c8 authored by Pietro Saccardi's avatar Pietro Saccardi
Browse files

Testing final render output.

parent aad17f0f
Loading
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -202,6 +202,13 @@ class general_plugin_ifauthex_test extends DokuWikiTest
        auth_expr_parse(str_repeat('(', $depthLimit) . 'a && b' . str_repeat(')', $depthLimit));
    }

    public function test_output() {
        $info = array();
        $instructions = p_get_instructions('<ifauth nonexistent>hideme</ifauth><ifauth !nonexistent>showme</ifauth>');
        $xhtml = p_render('xhtml', $instructions, $info);
        $this->assertTrue(stristr($xhtml, 'showme') !== false);
        $this->assertTrue(stristr($xhtml, 'hideme') === false);
    }
    /**
     * Simple test to make sure the plugin.info.txt is in correct format
     */