diff --git a/lib/Cake/Console/Command/Task/ViewTask.php b/lib/Cake/Console/Command/Task/ViewTask.php index efc574aa4cc..0228c32adbb 100644 --- a/lib/Cake/Console/Command/Task/ViewTask.php +++ b/lib/Cake/Console/Command/Task/ViewTask.php @@ -327,7 +327,7 @@ public function customAction() { $this->hr(); $this->out(__d('cake_console', 'Controller Name: %s', $this->controllerName)); $this->out(__d('cake_console', 'Action Name: %s', $action)); - $this->out(__d('cake_console', 'Path: %s', $this->params['app'] . DS . 'View' . DS . $this->controllerName . DS . Inflector::underscore($action) . ".ctp")); + $this->out(__d('cake_console', 'Path: %s', $this->getPath() . $this->controllerName . DS . Inflector::underscore($action) . ".ctp")); $this->hr(); $looksGood = $this->in(__d('cake_console', 'Look okay?'), array('y','n'), 'y'); if (strtolower($looksGood) == 'y') { diff --git a/lib/Cake/Test/Case/Console/Command/Task/ViewTaskTest.php b/lib/Cake/Test/Case/Console/Command/Task/ViewTaskTest.php index 581615b46a6..1652b9267a0 100644 --- a/lib/Cake/Test/Case/Console/Command/Task/ViewTaskTest.php +++ b/lib/Cake/Test/Case/Console/Command/Task/ViewTaskTest.php @@ -431,7 +431,6 @@ public function testBakeActions() { */ public function testCustomAction() { $this->Task->controllerName = 'ViewTaskComments'; - $this->Task->params['app'] = APP; $this->Task->expects($this->any())->method('in') ->will($this->onConsecutiveCalls('', 'my_action', 'y'));