source: trunk/tests/NavTest.php @ 238

Last change on this file since 238 was 202, checked in by scdev, 18 years ago

Q - updated usage of $nav.

File size: 2.8 KB
RevLine 
[1]1<?php
2/// FIXME: Tests not implemented.
3return;
4
5/**
[202]6 * PHPUnit test case for Navigation
[42]7 *
8 * The method skeletons below need to be filled in with
9 * real data so that the tests will run correctly. Replace
10 * all EXPECTED_VAL and PARAM strings with real data.
11 *
[1]12 * Created with PHPUnit_Skeleton on 2005-08-09
13 */
14require_once 'PHPUnit.php';
[202]15class NavigationTest extends PHPUnit_TestCase {
[1]16
[202]17    var $Navigation;
[1]18
[202]19    function NavigationTest($name)
[1]20    {
21        $this->PHPUnit_TestCase($name);
22    }
23
24    function setUp()
25    {
26        require dirname(__FILE__) . '/_config.inc.php';
[202]27        require_once '../lib/Navigation.inc.php';
28        $this->Navigation =& new Navigation(PARAM);
[1]29    }
30
31    function tearDown()
32    {
[202]33        unset($this->Navigation);
[1]34    }
35
36    function test_addpage()
37    {
[202]38        $result = $this->Navigation->addpage(PARAM);
[1]39        $expected = EXPECTED_VAL;
40        $this->assertEquals($expected, $result);
41    }
42
43    function test_setfeature()
44    {
[202]45        $result = $this->Navigation->setfeature(PARAM);
[1]46        $expected = EXPECTED_VAL;
47        $this->assertEquals($expected, $result);
48    }
49
50    function test_clearpath()
51    {
[202]52        $result = $this->Navigation->clearpath(PARAM);
[1]53        $expected = EXPECTED_VAL;
54        $this->assertEquals($expected, $result);
55    }
56
57    function test_getfeature()
58    {
[202]59        $result = $this->Navigation->getfeature(PARAM);
[1]60        $expected = EXPECTED_VAL;
61        $this->assertEquals($expected, $result);
62    }
63
64    function test_gettitle()
65    {
[202]66        $result = $this->Navigation->gettitle(PARAM);
[1]67        $expected = EXPECTED_VAL;
68        $this->assertEquals($expected, $result);
69    }
70
71    function test_printtitle()
72    {
[202]73        $result = $this->Navigation->printtitle(PARAM);
[1]74        $expected = EXPECTED_VAL;
75        $this->assertEquals($expected, $result);
76    }
77
78    function test_getpath()
79    {
[202]80        $result = $this->Navigation->getpath(PARAM);
[1]81        $expected = EXPECTED_VAL;
82        $this->assertEquals($expected, $result);
83    }
84
85    function test_printpath()
86    {
[202]87        $result = $this->Navigation->printpath(PARAM);
[1]88        $expected = EXPECTED_VAL;
89        $this->assertEquals($expected, $result);
90    }
91
92    function test_getbreadcrumbs()
93    {
[202]94        $result = $this->Navigation->getbreadcrumbs(PARAM);
[1]95        $expected = EXPECTED_VAL;
96        $this->assertEquals($expected, $result);
97    }
98
99    function test_printbreadcrumbs()
100    {
[202]101        $result = $this->Navigation->printbreadcrumbs(PARAM);
[1]102        $expected = EXPECTED_VAL;
103        $this->assertEquals($expected, $result);
104    }
105
106    function test_currentpage()
107    {
[202]108        $result = $this->Navigation->currentpage(PARAM);
[1]109        $expected = EXPECTED_VAL;
110        $this->assertEquals($expected, $result);
111    }
112
113}
114// Running the test.
[202]115$suite = new PHPUnit_TestSuite('NavigationTest');
[1]116$result = PHPUnit::run($suite);
117echo $result->toString();
118?>
Note: See TracBrowser for help on using the repository browser.