function it_returns_a_price_collection_even_if_the_data_is_empty($productBuilder, ProductValueInterface $priceValue, ProductPriceInterface $price, ArrayCollection $priceCollection) { $productBuilder->addPriceForCurrency(Argument::cetera())->willReturn($price); $priceValue->addPrice($price)->shouldBeCalled(); $priceValue->getPrices()->willReturn($priceCollection); $context = ['value' => $priceValue, 'price_currency' => 'WillNotBeUsed']; $this->denormalize('', 'className', null, $context)->shouldReturn($priceCollection); $this->denormalize(null, 'className', null, $context)->shouldReturn($priceCollection); }