Add test for --thanks

This commit is contained in:
Owen Voke
2020-07-01 10:27:12 +01:00
parent 64a8ed04ff
commit 8e203e914e
2 changed files with 20 additions and 2 deletions

View File

@ -0,0 +1,14 @@
<?php
use Pest\Plugins\Thanks;
use Symfony\Component\Console\Output\BufferedOutput;
it('outputs funding options when --thanks is used')->skip('The plugin uses `exit()` so not sure how to implement this');
it('does not output funding options when --thanks is not used', function () {
$output = new BufferedOutput();
$plugin = new Thanks($output);
$plugin->handleArguments(['foo', 'bar']);
assertEquals('', $output->fetch());
});