Queues a command instance into the pipeline buffer.
public executeCommand ( Predis\Command\CommandInterface $command ) | ||
$command | Predis\Command\CommandInterface | Command instance to be queued in the buffer. |
/** * @group disconnected */ public function testExecuteCommandDoesNotSendCommandsWithoutExecute() { $profile = Profile\Factory::getDefault(); $connection = $this->getMock('Predis\\Connection\\NodeConnectionInterface'); $connection->expects($this->never())->method('writeRequest'); $connection->expects($this->never())->method('readResponse'); $pipeline = new Pipeline(new Client($connection)); $pipeline->executeCommand($profile->createCommand('echo', array('one'))); $pipeline->executeCommand($profile->createCommand('echo', array('two'))); $pipeline->executeCommand($profile->createCommand('echo', array('three'))); }