We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6fd2727 commit bd384b8Copy full SHA for bd384b8
tests/static-analysis/TestUsingCallbacks.php
@@ -27,11 +27,16 @@ public function testWillSayHelloAndCheckCallbackInput(): void
27
$mock
28
->expects(self::once())
29
->method('hey')
30
- ->with(self::callback(static function (string $input): bool {
31
- self::assertStringContainsString('Joe', $input);
32
-
33
- return true;
34
- }))
+ ->with(
+ self::callback(
+ /** @psalm-param non-empty-string $input */
+ static function (string $input): bool {
+ self::assertStringContainsString('Joe', $input);
35
+
36
+ return true;
37
+ }
38
+ )
39
40
->willReturn('Hey Joe!');
41
42
self::assertSame('Hey Joe!', $mock->hey('Joe'));
0 commit comments