Inheritance: extends Symfony\Bundle\FrameworkBundle\Test\WebTestCase, use trait Elcodi\Bundle\CoreBundle\Container\Traits\ContainerAccessorTrait
Ejemplo n.º 1
0
 /**
  * Set up.
  */
 public function setUp()
 {
     $this->reloadScenario();
     parent::setUp();
     $this->newsletterManager = $this->get('elcodi.manager.newsletter');
     $this->newsletterSubscriptionRepository = $this->getRepository('newsletter_subscription');
 }
Ejemplo n.º 2
0
 /**
  * Skipping tests if Twig is not installed
  */
 public function setUp()
 {
     parent::setUp();
     if (!class_exists('Twig_Extension')) {
         $this->markTestSkipped("Twig extension not installed");
     }
 }
 /**
  * Set up.
  */
 public function setUp()
 {
     parent::setUp();
     $this->cart = $this->get('elcodi.factory.cart')->create();
     $this->purchasable = $this->createPurchasable();
     $this->cartLine = $this->get('elcodi.factory.cart_line')->create()->setPurchasable($this->purchasable)->setPurchasableAmount($this->purchasable->getPrice())->setAmount($this->purchasable->getPrice())->setQuantity(1);
     $this->get('elcodi.event_dispatcher.cart')->dispatchCartLoadEvents($this->cart);
 }
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     /**
      * @var LocationProviderAdapterInterface $locationProviderAdapter
      */
     $this->locationProviderAdapter = $this->get('elcodi.location_provider_adapter.service');
 }
Ejemplo n.º 5
0
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     /**
      * @var ZoneFactory $zoneFactory
      */
     $zoneFactory = $this->getFactory('zone');
     $this->zone = $zoneFactory->create()->setCode('UUEE')->setName('European Union');
     $this->flush($this->zone);
     $this->clear($this->zone);
 }
Ejemplo n.º 6
0
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     /**
      * @var CartOrderTransformer $cartOrderTransformer
      */
     $cartOrderTransformer = $this->get('elcodi.transformer.cart_order');
     /**
      * @var CartInterface $cart
      */
     $this->cart = $this->find('cart', 2);
     $this->get('elcodi.event_dispatcher.cart')->dispatchCartLoadEvents($this->cart);
     $this->order = $cartOrderTransformer->createOrderFromCart($this->cart);
 }
 public function setUp()
 {
     parent::setUp();
     /**
      * Full cart from fixtures
      *
      * @var CartInterface $cart
      * @var CouponInterface $coupon
      */
     $this->cart = $this->find('cart', 2);
     $this->cartEventDispatcher = $this->get('elcodi.event_dispatcher.cart');
     $this->cartEventDispatcher->dispatchCartLoadEvents($this->cart);
     $this->cartCouponManager = $this->get('elcodi.manager.cart_coupon');
 }
Ejemplo n.º 8
0
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     /**
      * @var OrderLineStateEventDispatcher $orderLineStateEventDispatcher
      * @var OrderLineHistoryFactory       $orderLineHistoryFactory
      * @var OrderLineFactory              $orderLineFactory
      */
     $orderLineStateEventDispatcher = $this->get('elcodi.order_line_state_event_dispatcher');
     $orderLineHistoryFactory = $this->get('elcodi.factory.order_line_history');
     $orderLineFactory = $this->get('elcodi.factory.order_line');
     $orderLineManager = new OrderLineManager($orderLineStateEventDispatcher, $orderLineHistoryFactory, $orderLineFactory, new OrderStateManager(['A' => ['B'], 'B' => ['C', 'E'], 'C' => ['B', 'D'], 'D' => ['E'], 'E' => []]));
     $this->orderManager = new OrderManager($orderLineManager, new OrderStateManager(['A' => ['B'], 'B' => ['C', 'E'], 'C' => ['B', 'D'], 'D' => ['E'], 'E' => []]));
     $this->orderLineStateEventDispatcher = $orderLineStateEventDispatcher;
     $this->orderLineManager = $orderLineManager;
     $this->orderLineManager = $orderLineManager;
 }
 /**
  * Setup.
  */
 public function setUp()
 {
     parent::setUp();
     $this->categoryDirector = $this->get('elcodi.director.category');
 }
Ejemplo n.º 10
0
 /**
  * Setup.
  */
 public function setUp()
 {
     parent::setUp();
     $this->menuManager = $this->get('elcodi.manager.menu');
 }
Ejemplo n.º 11
0
 /**
  * Set up
  */
 public function setUp()
 {
     parent::setUp();
     $this->ruleManager = $this->get('elcodi.manager.rule');
 }
Ejemplo n.º 12
0
 public function setUp()
 {
     parent::setUp();
     $this->client = static::createClient();
 }
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     $this->productCollectionProvider = $this->get('elcodi.product_collection_provider');
 }
 /**
  * load fixtures method
  *
  * This method is only called if create Schema is set to true
  *
  * Only load fixtures if loadFixtures() is set to true.
  * All other methods will be loaded if this one is loaded.
  *
  * Otherwise, will return.
  *
  * @return $this Self object
  */
 protected function loadFixtures()
 {
     parent::loadFixtures();
     self::$application->run(new ArrayInput(['command' => 'elcodi:plugins:load', '--no-interaction' => true, '--quiet' => true]));
 }
Ejemplo n.º 15
0
 /**
  * Set up
  */
 public function setUp()
 {
     parent::setUp();
     $this->newsletterManager = $this->get('elcodi.core.newsletter.service.newsletter_manager');
     $this->newsletterSubscriptionRepository = $this->getRepository('newsletter_subscription');
 }
Ejemplo n.º 16
0
 /**
  * Setup.
  */
 public function setUp()
 {
     parent::setUp();
     $this->categoryRepository = $this->get('elcodi.repository.category');
 }
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     $this->categoryRepository = $this->get('elcodi.repository.category');
     $this->productDirector = $this->get('elcodi.director.product');
 }
Ejemplo n.º 18
0
 /**
  * Setup
  */
 public function setUp()
 {
     parent::setUp();
     $this->categoryManager = $this->get('elcodi.category_manager');
 }