Skip to content

Commit

Permalink
Merge pull request #4401 from BenMorel/unused-var
Browse files Browse the repository at this point in the history
Add missing instanceof check
  • Loading branch information
morozov authored Nov 3, 2020
2 parents 83113ce + d76bf72 commit 1a9da6d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
9 changes: 9 additions & 0 deletions psalm.xml
Original file line number Diff line number Diff line change
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
Original file line number Diff line number Diff line change
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 1a9da6d

Please sign in to comment.