From b0e23ddc7d4029b070404694011c53ec3d38e7a7 Mon Sep 17 00:00:00 2001 From: mark_story Date: Wed, 7 Jan 2009 20:16:52 +0000 Subject: [PATCH] Adding additional tests to requestAction() for requests with named parameters. git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@7973 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/tests/cases/libs/object.test.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cake/tests/cases/libs/object.test.php b/cake/tests/cases/libs/object.test.php index 21b707bc075..a1224528c79 100644 --- a/cake/tests/cases/libs/object.test.php +++ b/cake/tests/cases/libs/object.test.php @@ -556,6 +556,13 @@ function testRequestActionParamParseAndPass() { $this->assertEqual($result['action'], 'params_pass'); $this->assertEqual($result['form'], array()); $this->assertEqual($result['plugin'], null); + + $result = $this->object->requestAction('/request_action/params_pass/sort:desc/limit:5'); + $expected = array('sort' => 'desc', 'limit' => 5,); + $this->assertEqual($result['named'], $expected); + + $result = $this->object->requestAction(array('controller' => 'request_action', 'action' => 'params_pass'), array('named' => array('sort' => 'desc', 'limit' => 5))); + $this->assertEqual($result['named'], $expected); } /** * test requestAction and POST parameter passing, and not passing when url is an array.