3 * Ethna_View_404_Test.php
5 * @author Yoshinari Takaoka <takaoka@beatcraft.com>
9 require_once ETHNA_INSTALL_BASE . '/test/Ethna_MockProject.php';
11 //{{{ Ethna_View_404_Test
13 * Test Case For Ethna_View_404
17 class Ethna_View_404_Test extends Ethna_UnitTestBase
25 $this->test_ctl =& new Ethna_Controller();
26 $this->test_backend =& $this->test_ctl->getBackend();
27 $this->view_404 = new Ethna_View_404($this->test_backend, '404', NULL);
32 unset($GLOBALS['_Ethna_controller']);
35 function test_redirect_404()
37 $project =& new Ethna_MockProject();
40 // add mock action for redirect
41 $action_skel = ETHNA_TEST_SKELDIR . 'skel.action.404.php';
42 $project->runCmd('add-action',
49 $out = $project->runMain('return404');
50 $this->assertPattern("/404 Not Found/", $out);