Skip to content

Commit 10f76cd

Browse files
committed
DKIMTest: make exception expectation more specific
As things were, the `DKIMTest::testDKIMSignOpenSSLNotAvailableException()` test _could_ potentially pass even when another `Exception` than the `PHPMailer\PHPMailer\Exception` was being thrown, as _all_ exceptions extend the PHP native `Exception` class. Now this risk is not that high, as there is also a check on the exception message, but still. Making the exception expectation more specific (by changing the import `use` statement), should still make the test more stable.
1 parent aaddfdf commit 10f76cd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/PHPMailer/DKIMTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
namespace PHPMailer\Test\PHPMailer;
1515

16-
use Exception;
16+
use PHPMailer\PHPMailer\Exception;
1717
use PHPMailer\PHPMailer\PHPMailer;
1818
use PHPMailer\Test\SendTestCase;
1919

0 commit comments

Comments
 (0)