Skip to content

Commit

Permalink
Making ControllerTestCase abstract, that way PHP won't complain about…
Browse files Browse the repository at this point in the history
… empty test cases, closes #1868
  • Loading branch information
lorenzo committed Jul 31, 2011
1 parent b15c77e commit eaa0163
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 5 additions & 1 deletion lib/Cake/Test/Case/TestSuite/ControllerTestCaseTest.php
Expand Up @@ -98,6 +98,10 @@ class ControllerTestCaseTestController extends AppController {

}

/**
* Used to get a testable concrete class of the test subject
*/
class TestingControllerTestCase extends ControllerTestCase {}

/**
* ControllerTestCaseTest
Expand Down Expand Up @@ -128,7 +132,7 @@ public function setUp() {
'View' => array(CAKE . 'Test' . DS . 'test_app' . DS . 'View' . DS)
));
CakePlugin::loadAll();
$this->Case = new ControllerTestCase();
$this->Case = new TestingControllerTestCase();
Router::reload();
}

Expand Down
2 changes: 1 addition & 1 deletion lib/Cake/TestSuite/ControllerTestCase.php
Expand Up @@ -98,7 +98,7 @@ public function afterRender($viewFile) {
*
* @package Cake.TestSuite
*/
class ControllerTestCase extends CakeTestCase {
abstract class ControllerTestCase extends CakeTestCase {

/**
* The controller to test in testAction
Expand Down

0 comments on commit eaa0163

Please sign in to comment.