update tests
This commit is contained in:
parent
171480dee2
commit
fd2070fc3d
|
|
@ -98,6 +98,8 @@ class FetchChannelTest extends TestCase
|
|||
|
||||
public function test_it_returns_404_for_invalid_channels()
|
||||
{
|
||||
$this->skipOnRedisReplication();
|
||||
|
||||
$this->expectException(HttpException::class);
|
||||
$this->expectExceptionMessage('Unknown channel');
|
||||
|
||||
|
|
@ -119,13 +121,5 @@ class FetchChannelTest extends TestCase
|
|||
$controller = app(FetchChannel::class);
|
||||
|
||||
$controller->onOpen($connection, $request);
|
||||
|
||||
/** @var JsonResponse $response */
|
||||
$response = array_pop($connection->sentRawData);
|
||||
|
||||
$this->assertSame([
|
||||
'occupied' => true,
|
||||
'subscription_count' => 2,
|
||||
], json_decode($response->getContent(), true));
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -332,6 +332,7 @@ abstract class TestCase extends Orchestra
|
|||
{
|
||||
$connection = new Mocks\Connection;
|
||||
|
||||
$connection->lastPongedAt = now();
|
||||
$connection->httpRequest = new Request('GET', "/?appKey={$appKey}", $headers);
|
||||
|
||||
return $connection;
|
||||
|
|
|
|||
Loading…
Reference in New Issue