From df4cd12d0fb7c6c8bdf91408baf30f87b9ded13c Mon Sep 17 00:00:00 2001 From: mark_story Date: Tue, 3 Nov 2009 17:19:02 -0500 Subject: [PATCH] Fixing RequestHandler test case when app/views/posts/index.ctp is available. --- .../libs/controller/components/request_handler.test.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cake/tests/cases/libs/controller/components/request_handler.test.php b/cake/tests/cases/libs/controller/components/request_handler.test.php index cc702d48e24..f8a97173495 100644 --- a/cake/tests/cases/libs/controller/components/request_handler.test.php +++ b/cake/tests/cases/libs/controller/components/request_handler.test.php @@ -561,7 +561,9 @@ function testClientProperties() { function testAjaxRedirectAsRequestAction() { $_SERVER['HTTP_X_REQUESTED_WITH'] = 'XMLHttpRequest'; $this->_init(); - App::build(array('views' => array(TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'views'. DS))); + App::build(array( + 'views' => array(TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'views'. DS) + ), true); $this->Controller->RequestHandler = new NoStopRequestHandler($this); $this->Controller->RequestHandler->expectOnce('_stop'); @@ -574,6 +576,7 @@ function testAjaxRedirectAsRequestAction() { $this->assertPattern('/posts index/', $result, 'RequestAction redirect failed.'); unset($_SERVER['HTTP_X_REQUESTED_WITH']); + App::build(); } } ?> \ No newline at end of file