Skip to content

Commit

Permalink
CoverageDoesNotExistException - fix message (#870)
Browse files Browse the repository at this point in the history
  • Loading branch information
kubawerlos authored and maks-rafalko committed Nov 30, 2019
1 parent 1d79de5 commit c2bd612
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/TestFramework/Coverage/CoverageDoesNotExistException.php
Expand Up @@ -45,6 +45,7 @@ final class CoverageDoesNotExistException extends InfectionException
private const INFECTION_USAGE_SUGGESTION = <<<TXT
- Enable xdebug and run infection again
- Use phpdbg: phpdbg -qrr infection
- Enable pcov and run infection again
- Use --coverage option with path to the existing coverage report
- Use --initial-tests-php-options option with `-d zend_extension=xdebug.so` and/or any extra php parameters
TXT
Expand Down Expand Up @@ -84,7 +85,7 @@ public static function forFileAtPath(string $fileName, string $path): self
public static function unableToGenerate(): self
{
return new self(
'Neither phpdbg or xdebug has been found. One of those is required by Infection in order to generate coverage data. Either:' .
'Neither pcov, phpdbg or xdebug has been found. One of those is required by Infection in order to generate coverage data. Either:' .
"\n" .
self::INFECTION_USAGE_SUGGESTION
);
Expand Down
Expand Up @@ -53,6 +53,7 @@ public function test_with(): void
'Code Coverage does not exist. File file-index-path is not found. Check phpunit version Infection was run with and generated config files inside tempdir. Make sure to either: ' . "\n" .
'- Enable xdebug and run infection again' . "\n" .
'- Use phpdbg: phpdbg -qrr infection' . "\n" .
'- Enable pcov and run infection again' . "\n" .
'- Use --coverage option with path to the existing coverage report' . "\n" .
'- Use --initial-tests-php-options option with `-d zend_extension=xdebug.so` and/or any extra php parameters', $exception->getMessage()
);
Expand Down Expand Up @@ -87,9 +88,10 @@ public function test_for_correctly_escaped_output_of_subprocesses(): void

public function test_log_missed_debugger_or_coverage_option(): void
{
$message = 'Neither phpdbg or xdebug has been found. One of those is required by Infection in order to generate coverage data. Either:' . "\n" .
$message = 'Neither pcov, phpdbg or xdebug has been found. One of those is required by Infection in order to generate coverage data. Either:' . "\n" .
'- Enable xdebug and run infection again' . "\n" .
'- Use phpdbg: phpdbg -qrr infection' . "\n" .
'- Enable pcov and run infection again' . "\n" .
'- Use --coverage option with path to the existing coverage report' . "\n" .
'- Use --initial-tests-php-options option with `-d zend_extension=xdebug.so` and/or any extra php parameters';

Expand Down

0 comments on commit c2bd612

Please sign in to comment.