Skip to content

Commit

Permalink
Showing the available testcases when the testsuite shell is run with …
Browse files Browse the repository at this point in the history
…no params
  • Loading branch information
lorenzo committed Jul 14, 2010
1 parent ab6e3ee commit 1c08d48
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions cake/console/libs/testsuite.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,14 @@ public function main() {
$this->out(__('CakePHP Test Shell'));
$this->hr();

$args = $this->parseArgs();

if (empty($args['case'])) {
$this->available();
}

require_once CAKE . 'tests' . DS . 'lib' . DS . 'test_runner.php';
$testCli = new TestRunner($this->parseArgs());
$testCli = new TestRunner($args);
$testCli->run($this->runnerOptions());
}

Expand All @@ -132,7 +138,7 @@ public function available() {
$title = Inflector::humanize($plugin) . " Test Cases:";
$category = $plugin;
}

if (empty($testCases)) {
$this->out(__('No test cases available'));
return;
Expand Down

0 comments on commit 1c08d48

Please sign in to comment.