public it_should_clone_the_batch_collection ( ) |
function it_should_clone_the_batch_collection()
{
$batch = new Batch(Batch::TYPE['ADD'], 'foo', 'bar');
$batches = new BatchCollection();
$batches->add($batch);
$operation = new BatchModifyOperation('foo', $batches);
$new = clone $operation;
$batch->setAttribute('foobar');
$this->setBatchCollection($new->getBatchCollection());
$this->getBatchCollection()->get(0)->getAttribute()->shouldNotBeEqualTo('foobar');
}