Skip to content

Commit

Permalink
Add missing instanceof check
Browse files Browse the repository at this point in the history
  • Loading branch information
BenMorel committed Nov 3, 2020
1 parent 26fe027 commit d76bf72
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
9 changes: 9 additions & 0 deletions psalm.xml
Expand Up @@ -89,6 +89,15 @@
<file name="src/Schema/AbstractSchemaManager.php"/>
</errorLevel>
</PossiblyNullArgument>
<RedundantCondition>
<errorLevel type="suppress">
<!--
Requires a release of
https://github.com/sebastianbergmann/phpunit/commit/9c60d7d9fd3bfa80fa4aeab7090e1bbe0830dbcd
-->
<file name="tests/Driver/API/ExceptionConverterTest.php"/>
</errorLevel>
</RedundantCondition>
<TooFewArguments>
<errorLevel type="suppress">
<!--
Expand Down
1 change: 1 addition & 0 deletions tests/Driver/API/ExceptionConverterTest.php
Expand Up @@ -51,6 +51,7 @@ public function testConvertsException(

$dbalException = $this->converter->convert($driverException, $query);

self::assertInstanceOf($expectedClass, $dbalException);
self::assertSame($driverException->getCode(), $dbalException->getCode());
self::assertSame($driverException->getSQLState(), $dbalException->getSQLState());
self::assertSame($driverException, $dbalException->getPrevious());
Expand Down

0 comments on commit d76bf72

Please sign in to comment.