flows: denied action (#3194)

This commit is contained in:
Jens L
2022-07-02 17:37:57 +02:00
committed by GitHub
parent c39a5933e1
commit 17d33f4b19
23 changed files with 564 additions and 168 deletions

View File

@ -11,14 +11,13 @@ from authentik.lib.generators import generate_id
from authentik.tenants.models import Tenant
def create_test_flow(designation: FlowDesignation = FlowDesignation.STAGE_CONFIGURATION) -> Flow:
def create_test_flow(
designation: FlowDesignation = FlowDesignation.STAGE_CONFIGURATION, **kwargs
) -> Flow:
"""Generate a flow that can be used for testing"""
uid = generate_id(10)
return Flow.objects.create(
name=uid,
title=uid,
slug=slugify(uid),
designation=designation,
name=uid, title=uid, slug=slugify(uid), designation=designation, **kwargs
)