Skip to content

Commit a4967e3

Browse files
authored
Merge pull request #3221 from mehdihasanpour/cleanup
Cleanup
2 parents f640f63 + 880e8c7 commit a4967e3

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

tests/AppTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1763,7 +1763,7 @@ public function testHandleReturnsEmptyResponseBodyWithHeadRequestMethod(): void
17631763
$responseProphecy->getBody()->willReturn($streamProphecy->reveal());
17641764
$responseProphecy
17651765
->withBody(Argument::type(StreamInterface::class))
1766-
->will(function ($args) use ($streamProphecy) {
1766+
->will(function ($args) {
17671767
$this->getBody()->willReturn($args[0]);
17681768
return $this;
17691769
});
@@ -1869,7 +1869,7 @@ public function testCanBeReExecutedRecursivelyDuringDispatch(): void
18691869
$middlewareProphecy2->process(
18701870
Argument::type(ServerRequestInterface::class),
18711871
Argument::type(RequestHandlerInterface::class)
1872-
)->will(function ($args) use ($app) {
1872+
)->will(function ($args) {
18731873
/** @var ServerRequestInterface $request */
18741874
$request = $args[0];
18751875

tests/Mocks/MockStream.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,6 +263,6 @@ public function getMetadata($key = null)
263263

264264
$meta = stream_get_meta_data($this->stream);
265265

266-
return isset($meta[$key]) ? $meta[$key] : null;
266+
return $meta[$key] ?? null;
267267
}
268268
}

tests/Routing/RouteTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ class RouteTest extends TestCase
5050
*/
5151
public function createRoute($methods = 'GET', string $pattern = '/', $callable = null): Route
5252
{
53-
$callable = $callable ?? function (ServerRequestInterface $request, ResponseInterface $response) {
53+
$callable ??= function (ServerRequestInterface $request, ResponseInterface $response) {
5454
return $response;
5555
};
5656

0 commit comments

Comments
 (0)