Skip to content

Commit

Permalink
test subscription restore on reconnect
Browse files Browse the repository at this point in the history
  • Loading branch information
nekufa committed Dec 25, 2024
1 parent b3c6734 commit 0b1d55f
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/Functional/ClientTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,14 +33,17 @@ public function testConnectionTimeout(): void
public function testReconnect()
{
$client = $this->getClient();
$client->subscribe("tester");
$this->assertTrue($client->ping());
$this->assertCount(1, $client->getSubscriptions());

$property = new ReflectionProperty(Connection::class, 'socket');
$property->setAccessible(true);

fclose($property->getValue($client->connection));

$this->assertTrue($client->ping());
$this->assertCount(1, $client->getSubscriptions());
}

public function testPacketSizeSetter()
Expand Down

0 comments on commit 0b1d55f

Please sign in to comment.