fix tests when coverage is not available

This commit is contained in:
Fabio Ivona
2022-09-19 08:45:48 +02:00
parent df8a64b017
commit 97431f2622

View File

@ -17,7 +17,7 @@ it('adds coverage if --coverage exist', function () {
$arguments = $plugin->handleArguments(['--coverage']);
expect($arguments)->toEqual(['--coverage-php', Coverage::getPath()])
->and($plugin->coverage)->toBeTrue();
})->skip(! \Pest\Support\Coverage::isAvailable() || ! in_array('coverage', xdebug_info('mode'), true), 'Coverage is not available');
})->skip(! \Pest\Support\Coverage::isAvailable() || ! function_exists('xdebug_info') || ! in_array('coverage', xdebug_info('mode'), true), 'Coverage is not available');
it('adds coverage if --min exist', function () {
$plugin = new CoveragePlugin(new ConsoleOutput());