From 4541510e26b2b75abac698c74974bbe6c6de997e Mon Sep 17 00:00:00 2001 From: mark_story Date: Sun, 29 Jul 2012 22:37:41 -0400 Subject: [PATCH] Fix notice error when a missing action error is hit. --- lib/Cake/TestSuite/ControllerTestCase.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Cake/TestSuite/ControllerTestCase.php b/lib/Cake/TestSuite/ControllerTestCase.php index d6002f07a..c92b2af20 100644 --- a/lib/Cake/TestSuite/ControllerTestCase.php +++ b/lib/Cake/TestSuite/ControllerTestCase.php @@ -246,7 +246,7 @@ abstract class ControllerTestCase extends CakeTestCase { } $Dispatch->loadRoutes = $this->loadRoutes; $Dispatch->parseParams(new CakeEvent('ControllerTestCase', $Dispatch, array('request' => $request))); - if (!isset($request->params['controller'])) { + if (!isset($request->params['controller']) && Router::currentRoute()) { $this->headers = Router::currentRoute()->response->header(); return; }