lithium\tests\cases\net\http\RouterTest::testProcess PHP Method

testProcess() public method

public testProcess ( )
    public function testProcess()
    {
        Router::connect('/add/{:args}', array('controller' => 'tests', 'action' => 'add'));
        $request = Router::process(new Request(array('url' => '/add/foo/bar')));
        $params = array('controller' => 'Tests', 'action' => 'add', 'args' => array('foo', 'bar'));
        $this->assertEqual($params, $request->params);
        $this->assertEqual(array('controller'), $request->persist);
        $request = Router::process(new Request(array('url' => '/remove/foo/bar')));
        $this->assertEmpty($request->params);
    }
RouterTest