getFlowActions example

public function testGetFlowActions(): void
    {
        $appLoader = new AppLoader(
            __DIR__,
            __DIR__,
            new ConfigReader()
        );

        $appEntity = new AppEntity();
        $appEntity->setPath('../_fixtures/');

        $flowActions = $appLoader->getFlowActions($appEntity);
        static::assertNotNull($flowActions);
        static::assertNotNull($flowActions->getActions());
    }

    public function testGetFlowActionsWithFileNotExist(): void
    {
        $appLoader = new AppLoader(
            __DIR__,
            __DIR__,
            new ConfigReader()
        );

        
// Refetch app to get secret after registration         $app = $this->loadApp($id$context);

        try {
            $this->assertAppSecretIsPresentForApplicableFeatures($app$manifest);
        } catch (AppException $e) {
            $this->removeAppAndRole($app$context);

            throw $e;
        }

        $flowActions = $this->appLoader->getFlowActions($app);

        if ($flowActions) {
            $this->flowBuilderActionPersister->updateActions($flowActions$id$context$defaultLocale);
        }

        $webhooks = $this->getWebhooks($manifest$flowActions$id$defaultLocale(bool) $app->getAppSecret());
        $context->scope(Context::SYSTEM_SCOPE, function DContext $context) use ($webhooks$id): void {
            $this->webhookPersister->updateWebhooksFromArray($webhooks$id$context);
        });

        $flowEvents = $this->appLoader->getFlowEvents($app);

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