/** * @covers ::__construct * @covers ::beginBatch * @covers ::discardBatch * @expectedException Exception */ public function testANewBatchCanBeStartedAfterABatchHasAlreadyBeenDiscarded() { $this->producer->beginBatch(); $this->producer->discardBatch(); $this->producer->beginBatch(); $this->producer->getQueue('some-queue-name')->push(1); $consumer = $this->adapter_factory->getConsumer('some-queue-name'); $consumer->consumeMessage(function () { }); }
public function discardBatch() { $this->producer->discardBatch(); }