wip
This commit is contained in:
parent
cf40ec57f4
commit
f3b706de52
|
|
@ -29,6 +29,31 @@ class SendMessageTest extends TestCase
|
|||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function can_send_message_on_redis_replication()
|
||||
{
|
||||
$this->skipOnLocalReplication();
|
||||
|
||||
// Because the Pusher server is not active,
|
||||
// we expect it to turn out ok: false.
|
||||
// However, the driver is set to redis,
|
||||
// so Redis would take care of this
|
||||
// and stream the message to all active servers instead.
|
||||
|
||||
$this->actingAs(factory(User::class)->create())
|
||||
->json('POST', route('laravel-websockets.event'), [
|
||||
'appId' => '1234',
|
||||
'key' => 'TestKey',
|
||||
'secret' => 'TestSecret',
|
||||
'channel' => 'test-channel',
|
||||
'event' => 'some-event',
|
||||
'data' => json_encode(['data' => 'yes']),
|
||||
])
|
||||
->seeJson([
|
||||
'ok' => true,
|
||||
]);
|
||||
}
|
||||
|
||||
/** @test */
|
||||
public function cant_send_message_for_invalid_app()
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue