mirror of
https://github.com/predis/predis.git
synced 2026-08-24 17:39:36 +00:00
Drop support for streamable multibulk responses.
Supporting this feature has been problematic and leaded to some ugly code to make abstractions such as pipelines and transactions aware of these kind of response objects. Furthermore, it was not possible to add them to all the connection classes due to implementation limits. For such reasons Predis do not support them globally anymore, but the actual classes are still shipped within the library so that they can be used to build custom stuff at a level lower than client (that is, unless we decide to remove them for good before going stable).
This commit is contained in:
@@ -87,20 +87,6 @@ class StreamConnectionTest extends ConnectionTestCase
|
||||
$this->assertTrue($connection->isConnected());
|
||||
}
|
||||
|
||||
/**
|
||||
* @group connected
|
||||
*/
|
||||
public function testReadsMultibulkRepliesAsIterators()
|
||||
{
|
||||
$connection = $this->getConnection($profile, true, array('iterable_multibulk' => true));
|
||||
|
||||
$connection->executeCommand($profile->createCommand('rpush', array('metavars', 'foo', 'hoge', 'lol')));
|
||||
$connection->writeCommand($profile->createCommand('lrange', array('metavars', 0, -1)));
|
||||
|
||||
$this->assertInstanceOf('Predis\Iterator\MultiBulkResponse', $iterator = $connection->read());
|
||||
$this->assertSame(array('foo', 'hoge', 'lol'), iterator_to_array($iterator));
|
||||
}
|
||||
|
||||
/**
|
||||
* @group connected
|
||||
* @expectedException Predis\Protocol\ProtocolException
|
||||
|
||||
Reference in New Issue
Block a user