Exemple #1
0
 /**
  * @group disconnected
  */
 public function testConstructorWithReplicationArgument()
 {
     $replication = new MasterSlaveReplication();
     $factory = new ConnectionFactory();
     $factory->createReplication($replication, array('tcp://host1?alias=master', 'tcp://host2?alias=slave'));
     $client = new Client($replication);
     $this->assertInstanceOf('Predis\\Network\\IConnectionReplication', $client->getConnection());
     $this->assertSame($replication, $client->getConnection());
 }