Show
Ignore:
Timestamp:
03/13/06 21:10:15 (6 years ago)
Author:
haas
Message:

ActionController? doc done

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/trax/test/ActionControllerTest.php

    r163 r174  
    100100        $ac = new ActionController; 
    101101        //  this URL doesn't match any route 
    102         $_SERVER['REDIRECT_URL'] = '~haas/foo/bar'; 
     102        $_SERVER['REDIRECT_URL'] = '/~haas/foo/bar'; 
    103103        $this->assertFalse($ac->recognize_route()); 
    104104        //  this URL matches but the controller doesn't exist 
    105         $_SERVER['REDIRECT_URL'] = '~haas/nocontroller/foo/bar'; 
     105        $_SERVER['REDIRECT_URL'] = '/~haas/nocontroller/foo/bar'; 
    106106        $this->assertFalse($ac->recognize_route()); 
    107107        //  this URL matches and the controller is where it should be 
    108         $_SERVER['REDIRECT_URL'] = '~haas/products/bar'; 
     108        $_SERVER['REDIRECT_URL'] = '/~haas/products/bar'; 
    109109        $this->assertTrue($ac->recognize_route()); 
    110110    } 
     
    155155        $ac = new ActionController; 
    156156        //  this URL doesn't match any route 
    157         $_SERVER['REDIRECT_URL'] = '~haas/foo/bar'; 
     157        $_SERVER['REDIRECT_URL'] = '/~haas/foo/bar'; 
    158158        try { 
    159159            $ac->process_route(); 
     
    180180        $ac = new ActionController; 
    181181        //  this URL matches default route 
    182         $_SERVER['REDIRECT_URL'] = '~haas/nocontroller/foo/bar'; 
     182        $_SERVER['REDIRECT_URL'] = '/~haas/nocontroller/foo/bar'; 
    183183        try { 
    184184            $ac->process_route(); 
     
    207207        //  this URL matches default route, but the controller 
    208208        //  file doesn't have a Noclass class 
    209         $_SERVER['REDIRECT_URL'] = '~haas/noclass/foo/bar'; 
     209        $_SERVER['REDIRECT_URL'] = '/~haas/noclass/foo/bar'; 
    210210        try { 
    211211            $ac->process_route(); 
     
    234234//        $ac = new ActionController; 
    235235//        //  should invoke CatalogController 
    236 //        $_SERVER['REDIRECT_URL'] = '~haas/products/bar'; 
     236//        $_SERVER['REDIRECT_URL'] = '/~haas/products/bar'; 
    237237//        $ac->process_route(); 
    238238//        // Remove the following line when you implement this test.