protected function _help()
{
$terminal = $this->terminal();
if (!$this->commandLine()->get('no-header')) {
$terminal->write($terminal->kahlan() . "\n\n");
$terminal->write($terminal->kahlanBaseline(), 'dark-grey');
$terminal->write("\n\n");
}
$help = <<<EOD
Usage: kahlan [options]
Configuration Options:
--config=<file> The PHP configuration file to use (default: `'kahlan-config.php'`).
--src=<path> Paths of source directories (default: `['src']`).
--spec=<path> Paths of specification directories (default: `['spec']`).
--pattern=<pattern> A shell wildcard pattern (default: `['*Spec.php', '*.spec.php']`).
Reporter Options:
--reporter=<name>[:<output_file>] The name of the text reporter to use, the buit-in text reporters
are `'dot'`, `'bar'`, `'json'`, `'tap'` & `'verbose'` (default: `'dot'`).
You can optionally redirect the reporter output to a file by using the
colon syntax (muliple --reporter options are also supported).
Code Coverage Options:
--coverage=<integer|string> Generate code coverage report. The value specify the level of
detail for the code coverage report (0-4). If a namespace, class, or
method definition is provided, it will generate a detailed code
coverage of this specific scope (default `''`).
--clover=<file> Export code coverage report into a Clover XML format.
--istanbul=<file> Export code coverage report into an istanbul compatible JSON format.
--lcov=<file> Export code coverage report into a lcov compatible text format.
Test Execution Options:
--ff=<integer> Fast fail option. `0` mean unlimited (default: `0`).
--no-colors To turn off colors. (default: `false`).
--no-header To turn off header. (default: `false`).
--include=<string> Paths to include for patching. (default: `['*']`).
--exclude=<string> Paths to exclude from patching. (default: `[]`).
--persistent=<boolean> Cache patched files (default: `true`).
--cc Clear cache before spec run. (default: `false`).
--autoclear Classes to autoclear after each spec (default: [
`'Kahlan\\Plugin\\Monkey'`,
`'Kahlan\\Plugin\\Call'`,
`'Kahlan\\Plugin\\Stub'`,
`'Kahlan\\Plugin\\Quit'`
])
Miscellaneous Options:
--help Prints this usage information.
--version Prints Kahlan version
Note: The `[]` notation in default values mean that the related option can accepts an array of values.
To add additionnal values, just repeat the same option many times in the command line.
EOD;
$terminal->write($help);
QuitStatement::quit();
}