mirror of
https://github.com/predis/predis.git
synced 2026-08-27 18:51:07 +00:00
Move IDistributionAlgorithm, HashRing and KetamaPureRing to the new Predis\Distribution namespace.
This commit is contained in:
@@ -93,7 +93,7 @@ class PredisClientFeaturesTestSuite extends PHPUnit_Framework_TestCase {
|
||||
$this->assertEquals('PING', $cmd->getCommandId());
|
||||
$this->assertFalse($cmd->closesConnection());
|
||||
$this->assertFalse($cmd->canBeHashed());
|
||||
$this->assertNull($cmd->getHash(new \Predis\Utilities\HashRing()));
|
||||
$this->assertNull($cmd->getHash(new \Predis\Distribution\HashRing()));
|
||||
$this->assertEquals("PING\r\n", $cmd());
|
||||
}
|
||||
|
||||
@@ -105,7 +105,7 @@ class PredisClientFeaturesTestSuite extends PHPUnit_Framework_TestCase {
|
||||
$this->assertEquals('GET', $cmd->getCommandId());
|
||||
$this->assertFalse($cmd->closesConnection());
|
||||
$this->assertTrue($cmd->canBeHashed());
|
||||
$this->assertNotNull($cmd->getHash(new \Predis\Utilities\HashRing()));
|
||||
$this->assertNotNull($cmd->getHash(new \Predis\Distribution\HashRing()));
|
||||
$this->assertEquals("GET key\r\n", $cmd());
|
||||
}
|
||||
|
||||
@@ -117,7 +117,7 @@ class PredisClientFeaturesTestSuite extends PHPUnit_Framework_TestCase {
|
||||
$this->assertEquals('SET', $cmd->getCommandId());
|
||||
$this->assertFalse($cmd->closesConnection());
|
||||
$this->assertTrue($cmd->canBeHashed());
|
||||
$this->assertNotNull($cmd->getHash(new \Predis\Utilities\HashRing()));
|
||||
$this->assertNotNull($cmd->getHash(new \Predis\Distribution\HashRing()));
|
||||
$this->assertEquals("SET key 5\r\nvalue\r\n", $cmd());
|
||||
}
|
||||
|
||||
@@ -129,7 +129,7 @@ class PredisClientFeaturesTestSuite extends PHPUnit_Framework_TestCase {
|
||||
$this->assertEquals('MSET', $cmd->getCommandId());
|
||||
$this->assertFalse($cmd->closesConnection());
|
||||
$this->assertFalse($cmd->canBeHashed());
|
||||
$this->assertNull($cmd->getHash(new \Predis\Utilities\HashRing()));
|
||||
$this->assertNull($cmd->getHash(new \Predis\Distribution\HashRing()));
|
||||
$this->assertEquals("*5\r\n$4\r\nMSET\r\n$4\r\nkey1\r\n$6\r\nvalue1\r\n$4\r\nkey2\r\n$6\r\nvalue2\r\n", $cmd());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user