onFlowSendMailActionEvent example


    public function testFlowActionRunsOnEnterState(array $productDownloads): void
    {
        $orderId = $this->placeOrder($productDownloads);

        $this->assertOrderWithoutGrantedAccess($orderId$productDownloads);

        $flowEvent = null;
        $flowListener = function DFlowSendMailActionEvent $event) use (&$flowEvent): void {
            $event = $this->onFlowSendMailActionEvent($event);

            if ($event instanceof FlowSendMailActionEvent) {
                $flowEvent = $event;
            }
        };
        $this->addEventListener($this->eventDispatcher, FlowSendMailActionEvent::class$flowListener);

        $mailEvent = null;
        $mailListener = function DMailBeforeSentEvent $event) use (&$mailEvent): void {
            $event = $this->onMailBeforeSentEvent($event);

            
Home | Imprint | This part of the site doesn't use cookies.