Skip to content

Commit

Permalink
qa: optimize AbstractAdapterTest
Browse files Browse the repository at this point in the history
Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
  • Loading branch information
boesing committed Aug 1, 2021
1 parent 16f8af7 commit 7204cb2
Show file tree
Hide file tree
Showing 2 changed files with 228 additions and 277 deletions.
47 changes: 6 additions & 41 deletions psalm-baseline.xml
Original file line number Diff line number Diff line change
Expand Up @@ -503,9 +503,7 @@
</RedundantCastGivenDocblockType>
</file>
<file src="src/Storage/AdapterPluginManager.php">
<NonInvariantDocblockPropertyType occurrences="3">
<code>$aliases</code>
<code>$factories</code>
<NonInvariantDocblockPropertyType occurrences="1">
<code>$instanceOf</code>
</NonInvariantDocblockPropertyType>
</file>
Expand Down Expand Up @@ -964,52 +962,28 @@
</MixedInferredReturnType>
</file>
<file src="test/Storage/Adapter/AbstractAdapterTest.php">
<InvalidReturnStatement occurrences="1">
<code>$adapter</code>
</InvalidReturnStatement>
<InvalidReturnType occurrences="1">
<code>AbstractAdapter&amp;MockObject</code>
</InvalidReturnType>
<InvalidScalarArgument occurrences="1">
<code>'123'</code>
</InvalidScalarArgument>
<MissingClosureParamType occurrences="7">
<MissingClosureParamType occurrences="1">
<code>$event</code>
<code>$event</code>
<code>$event</code>
<code>$event</code>
<code>$event</code>
<code>$k</code>
<code>$success</code>
</MissingClosureParamType>
<MissingClosureReturnType occurrences="4">
<MissingClosureReturnType occurrences="1">
<code>function ($event) use ($retVal) {</code>
<code>function ($event) use (&amp;$eventList) {</code>
<code>function ($event) use (&amp;$eventList) {</code>
<code>function ($event) use (&amp;$eventList) {</code>
</MissingClosureReturnType>
<MixedArgument occurrences="1">
<code>$success</code>
</MixedArgument>
<MixedArrayAssignment occurrences="4">
<MixedArrayAssignment occurrences="3">
<code>$eventList[]</code>
<code>$eventList[]</code>
<code>$eventList[]</code>
<code>$params[$k]</code>
</MixedArrayAssignment>
<MixedArrayOffset occurrences="1">
<code>$items[$k]</code>
</MixedArrayOffset>
<MixedAssignment occurrences="14">
<code>$eventList[]</code>
<code>$eventList[]</code>
<code>$eventList[]</code>
<code>$listener</code>
<code>$listenersOrListener</code>
<code>$mock</code>
<code>$mock</code>
<code>$params</code>
<code>$params[$k]</code>
<MixedAssignment occurrences="4">
<code>$result</code>
<code>$result</code>
<code>$rs</code>
Expand All @@ -1019,15 +993,9 @@
<MixedInferredReturnType occurrences="1">
<code>array</code>
</MixedInferredReturnType>
<MixedMethodCall occurrences="8">
<code>getName</code>
<code>getName</code>
<code>getName</code>
<code>getParams</code>
<MixedMethodCall occurrences="2">
<code>getResult</code>
<code>stopPropagation</code>
<code>will</code>
<code>will</code>
</MixedMethodCall>
<NullArgument occurrences="1">
<code>null</code>
Expand All @@ -1047,9 +1015,6 @@
<PossiblyUndefinedVariable occurrences="1">
<code>$success</code>
</PossiblyUndefinedVariable>
<RedundantCondition occurrences="1">
<code>assert($adapter instanceof AbstractAdapter)</code>
</RedundantCondition>
</file>
<file src="test/Storage/Adapter/AdapterOptionsTest.php">
<MixedArgument occurrences="1">
Expand Down
Loading

0 comments on commit 7204cb2

Please sign in to comment.