Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | |
100.00% |
8 / 8 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
||
| 1 | <?php |
| 2 | |
| 3 | declare(strict_types=1); |
| 4 | |
| 5 | use Phexium\Plugin\Mailer\Exception\MailSendFailedException; |
| 6 | |
| 7 | pest()->group('unit'); |
| 8 | |
| 9 | describe('Creation', function (): void { |
| 10 | it('creates exception with zero code', function (): void { |
| 11 | $exception = MailSendFailedException::withReason('SMTP timeout'); |
| 12 | expect($exception->getMessage())->toBe('Failed to send email: SMTP timeout'); |
| 13 | expect($exception->getCode())->toBe(0); |
| 14 | }); |
| 15 | }); |