/**
  * Test getter/setter for currency property
  */
 public function testGetSetCurrency()
 {
     $expectedCurrency = 'test-currency';
     $this->assertNull($this->price->getCurrency());
     $this->assertEntity($this->price->setCurrency($expectedCurrency));
     $this->assertEquals($expectedCurrency, $this->price->getCurrency());
 }
 function it_normalizes_a_price_into_mongodb_document($mongoFactory, ProductPrice $price, \MongoId $mongoId)
 {
     $mongoFactory->createMongoId()->willReturn($mongoId);
     $price->getCurrency()->willReturn('USD');
     $price->getData()->willReturn(9.99);
     $this->normalize($price, 'mongodb_document')->shouldReturn(['_id' => $mongoId, 'currency' => 'USD', 'data' => 9.99]);
 }
 /**
  * {@inheritDoc}
  */
 public function getCurrency()
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'getCurrency', array());
     return parent::getCurrency();
 }
 function it_normalizes_a_collection_of_product_prices($value, $attribute, ProductPrice $price1, ProductPrice $price2)
 {
     $attribute->isScopable()->willReturn(true);
     $attribute->isLocalizable()->willReturn(false);
     $value->getData()->willReturn([$price1, $price2]);
     $price1->getData()->willReturn('10.0');
     $price1->getCurrency()->willReturn('EUR');
     $price2->getData()->willReturn('12.0');
     $price2->getCurrency()->willReturn('currency_code');
     $this->normalize($value, 'MagentoArray', $this->globalContext)->shouldReturn(['attribute_code' => '12.0']);
 }