Skip to content

Commit

Permalink
Fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
2e3s committed Jul 15, 2023
1 parent d77df78 commit fce3f0e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 2 additions & 4 deletions src/Plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,14 +51,12 @@ private function hasPackage(string $packageName): bool

/**
* @throws OutOfBoundsException
*
* @psalm-suppress UnusedParam
*/
private function getPackageVersion(string $packageName): string
{
if (class_exists(Versions::class)) {
/**
* @psalm-suppress RedundantCondition
* @psalm-suppress RedundantCast
*/
return (string) Versions::getVersion($packageName);
}

Expand Down
2 changes: 1 addition & 1 deletion tests/acceptance/Collections.feature
Original file line number Diff line number Diff line change
Expand Up @@ -817,7 +817,7 @@ Feature: Collections
When I run Psalm
Then I see these errors
| Type | Message |
| InvalidScalarArgument | /Argument 1 of Doctrine\\Common\\Collections\\Collection::map expects Closure\(string=\):mixed, but (impure-)?Closure\(int\):bool provided\|Type (int\|string) should be a subtype of (int\|string)/ |
| InvalidScalarArgument | /Argument 1 of Doctrine\\Common\\Collections\\Collection::map expects Closure\(string=\):bool, but (impure-)?Closure\(int\):bool provided\|Type (int\|string) should be a subtype of (int\|string)/ |
And I see no other errors

@Collection::map
Expand Down

0 comments on commit fce3f0e

Please sign in to comment.