Skip to content

Commit

Permalink
Fixing bake's unit test detection so it checks for PHPUnit properly.
Browse files Browse the repository at this point in the history
Fixes #1505
  • Loading branch information
markstory committed Feb 5, 2011
1 parent 7b34d87 commit 8e267f7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cake/console/shells/shell.php
Expand Up @@ -628,7 +628,10 @@ public function createFile($path, $contents) {
* @return boolean Success
*/
protected function _checkUnitTest() {
if (App::import('vendor', 'simpletest' . DS . 'simpletest')) {
if (App::import('Vendor', 'phpunit', array('file' => 'PHPUnit' . DS . 'Autoload.php'))) {
return true;
}
if (@include 'PHPUnit' . DS . 'Autoload.php') {
return true;
}
$prompt = 'PHPUnit is not installed. Do you want to bake unit test files anyway?';
Expand Down

0 comments on commit 8e267f7

Please sign in to comment.