/** * @group disconnected */ public function testIsConnectedChecksConnectionState() { $loop = $this->getEventLoop(); $callback = function ($client, $connection) { }; $connection = $this->getMock('Predis\\Async\\Connection\\ConnectionInterface'); $connection->expects($this->once())->method('getEventLoop')->will($this->returnValue($loop)); $connection->expects($this->once())->method('isConnected'); $client = new Client($connection, $loop); $client->isConnected(); }