/**
  * @param UuidInterface $orderId
  * @param OrderStatusType $orderStatusType
  */
 public function setOrderStatus(UuidInterface $orderId, OrderStatusType $orderStatusType)
 {
     $order = $this->orderRepository->findOneById($orderId);
     $order->setStatus($orderStatusType);
     $this->update($order);
     if ($orderStatusType->isFinished()) {
         $this->lockOrderAttachments($order);
     }
 }
 public function testFindOneByIdThrowsException()
 {
     $this->setExpectedException(EntityNotFoundException::class, 'Order not found');
     $this->orderRepository->findOneById($this->dummyData->getId());
 }