getMasterAddressByName() public method

Get the hostname and port for a specific master
public getMasterAddressByName ( string $name ) : mixed
$name string
return mixed
Exemplo n.º 1
0
 public function testGetMasterAddressByName()
 {
     $address = $this->sentinel->getMasterAddressByName($this->sentinelConfig->clustername);
     $this->assertInternalType('array', $address);
     $this->assertCount(2, $address);
     $this->assertArrayHasKey(0, $address);
     $this->assertArrayHasKey(1, $address);
     $this->assertEquals($this->redisConfig[0]['host'], $address[0]);
     $this->assertEquals($this->redisConfig[0]['port'], $address[1]);
 }