xref: /dokuwiki/_test/tests/inc/parser/parser.inc.php (revision 3046a46462b44f28b1e5b1b25240a8ac4a859020)
1<?php
2
3require_once DOKU_INC . 'inc/parser/parser.php';
4require_once DOKU_INC . 'inc/parser/handler.php';
5
6abstract class TestOfDoku_Parser extends PHPUnit_Framework_TestCase {
7
8    var $P;
9    var $H;
10
11    function setup() {
12        $this->P = new Doku_Parser();
13        $this->H = new Doku_Handler();
14        $this->P->Handler = & $this->H;
15    }
16
17    function tearDown() {
18        unset($this->P);
19        unset($this->H);
20    }
21}
22
23function stripByteIndex($call) {
24    unset($call[2]);
25    if ($call[0] == "nest") {
26      $call[1][0] = array_map('stripByteIndex',$call[1][0]);
27    }
28    return $call;
29}
30