public function __construct(CartPriceRuleDiscount $cartPriceRuleDiscount, DTOBuilderFactoryInterface $dtoBuilderFactory)
 {
     $this->entity = $cartPriceRuleDiscount;
     $this->dtoBuilderFactory = $dtoBuilderFactory;
     $this->entityDTO = new CartPriceRuleDiscountDTO();
     $this->setId();
     $this->setTime();
     $this->entityDTO->quantity = $this->entity->getQuantity();
 }
 public function testCreateDefaults()
 {
     $product = $this->dummyData->getProduct();
     $cartPriceRuleDiscount = new CartPriceRuleDiscount($product);
     $this->assertSame(1, $cartPriceRuleDiscount->getQuantity());
     $this->assertSame($product, $cartPriceRuleDiscount->getProduct());
     $this->assertSame(null, $cartPriceRuleDiscount->getCartPriceRule());
 }