Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
msmakouz committed Mar 28, 2024
1 parent e759b9d commit 29b83ab
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions tests/Unit/HttpWorkerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ final class HttpWorkerTest extends TestCase
'uri' => 'http://localhost',
'attributes' => [Request::PARSED_BODY_ATTRIBUTE_NAME => false],
'query' => ['first' => 'value', 'arr' => ['foo bar', 'baz']],
'parsed' => false
'parsed' => false,
'body' => 'foo'
];

#[DataProvider('requestDataProvider')]
Expand All @@ -39,7 +40,7 @@ public function testWaitRequestFromArray(array $header, array $expected): void
$worker = $this->createMock(WorkerInterface::class);
$worker->expects($this->once())
->method('waitPayload')
->willReturn(new Payload(null, \json_encode($header)));
->willReturn(new Payload('foo', \json_encode($header)));

$worker = new HttpWorker($worker);

Expand All @@ -54,7 +55,7 @@ public function testWaitRequestFromProto(array $header, array $expected): void
$worker = $this->createMock(WorkerInterface::class);
$worker->expects($this->once())
->method('waitPayload')
->willReturn(new Payload(null, $request->serializeToString()));
->willReturn(new Payload('foo', $request->serializeToString()));

$worker = new HttpWorker($worker);

Expand Down

0 comments on commit 29b83ab

Please sign in to comment.