Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixing issue in Help command where full class descriptions were not…
… being printed properly.
  • Loading branch information
nateabele committed May 21, 2013
1 parent 97f0ca8 commit 04e20da
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions tests/cases/console/command/HelpTest.php
Expand Up @@ -172,6 +172,22 @@ public function testApiProperties() {
$result = $help->response->output;
$this->assertPattern("/{$expected}/s", $result);
}

/**
* Tests that the `Help` command prints a class' full description with all lines, not just the
* first.
*/
public function testPrintFullClassDoc() {
$command = new Help(array(
'request' => $this->request, 'classes' => $this->classes
));

$this->assertTrue($command->run('Create'));
$lines = explode(PHP_EOL, $command->response->output);

$offset = array_search('DESCRIPTION', $lines);
$this->assertEqual('OPTIONS', $lines[$offset + 3]);
}
}

?>

0 comments on commit 04e20da

Please sign in to comment.