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

testConnectingWithDefaultParams() public method

    public function testConnectingWithDefaultParams()
    {
        $result = Router::connect('/{:controller}/{:action}', array('action' => 'archive'));
        $expected = array('template' => '/{:controller}/{:action}', 'pattern' => '@^(?:/(?P<controller>[^\\/]+))(?:/(?P<action>[^\\/]+)?)?$@u', 'keys' => array('controller' => 'controller', 'action' => 'action'), 'params' => array('action' => 'archive'), 'match' => array(), 'meta' => array(), 'persist' => array('controller'), 'defaults' => array('action' => 'archive'), 'subPatterns' => array(), 'handler' => null);
        $this->assertEqual($expected, $result->export());
    }
RouterTest