Пример #1
0
 public function testChannel()
 {
     $order = new BaseOrder();
     $channel = new Channel();
     $channel->setName('store1');
     $order->setChannel($channel);
     $this->assertEquals('store1', $order->getChannel()->getName());
 }
Пример #2
0
 public function testCreateMerchandise()
 {
     $handler = $this->createProductHandler('test');
     $this->mgr->addProductHandler($handler);
     $product = $this->mgr->createProduct('test');
     $this->mgr->addMerchandiseHandler($this->getMock('Vespolina\\Product\\Handler\\MerchandiseHandler', null, array('Vespolina\\Entity\\Product\\Merchandise')));
     $channel = new Channel();
     $channel->setName('webshop1');
     $this->assertInstanceOf('Vespolina\\Entity\\Product\\MerchandiseInterface', $this->mgr->createMerchandise($product, $channel));
 }