@@ -45,7 +45,7 @@ |
||
| 45 | 45 | function it_throws_unexpected_type_excepotion_if_data_is_not_customer_type( |
| 46 | 46 | FormEvent $event, |
| 47 | 47 | ShopUserInterface $user |
| 48 | - ){ |
|
| 48 | + ) { |
|
| 49 | 49 | $event->getData()->willReturn($user); |
| 50 | 50 | |
| 51 | 51 | $this->shouldThrow(UnexpectedTypeException::class)->during('submit', [$event]); |
@@ -50,7 +50,8 @@ |
||
| 50 | 50 | $resolver->setDefault('validation_groups', function (FormInterface $form) { |
| 51 | 51 | $validationGroups = $this->validationGroups; |
| 52 | 52 | |
| 53 | - if ((bool) $form->get('promotionCoupon')->getNormData()) { // Validate the coupon if it was sent |
|
| 53 | + if ((bool) $form->get('promotionCoupon')->getNormData()) { |
|
| 54 | +// Validate the coupon if it was sent |
|
| 54 | 55 | $validationGroups[] = 'sylius_promotion_coupon'; |
| 55 | 56 | } |
| 56 | 57 | |
@@ -45,7 +45,7 @@ |
||
| 45 | 45 | SessionInterface $session, |
| 46 | 46 | OrderRepositoryInterface $orderRepository, |
| 47 | 47 | OrderInterface $cart |
| 48 | - ) { |
|
| 48 | + ) { |
|
| 49 | 49 | $session->has('session_key_name')->willReturn(true); |
| 50 | 50 | $session->get('session_key_name')->willReturn(12345); |
| 51 | 51 | $orderRepository->findCartById(12345)->willReturn($cart); |