code: def configured_app(minimal_app_for_api):
      app = minimal_app_for_api
      create_user(
          app,  # type:ignore
          username="test",
          role_name="Test",
          permissions=[(permissions.ACTION_CAN_READ, permissions.RESOURCE_DAG_CODE)],  # type: ignore
      )
      app.appbuilder.sm.sync_perm_for_dag(  # type: ignore
          TEST_DAG_ID,
          access_control={"Test": [permissions.ACTION_CAN_READ]},
      )
      app.appbuilder.sm.sync_perm_for_dag(  # type: ignore
          EXAMPLE_DAG_ID,
          access_control={"Test": [permissions.ACTION_CAN_READ]},
      )
      app.appbuilder.sm.sync_perm_for_dag(  # type: ignore
          TEST_MULTIPLE_DAGS_ID,
          access_control={"Test": [permissions.ACTION_CAN_READ]},
      )
      create_user(app, username="test_no_permissions", role_name="TestNoPermissions")  # type: ignore
  
      yield app
  
      delete_user(app, username="test")  # type: ignore
      delete_user(app, username="test_no_permissions")
  
imports: from __future__ import annotations
  import ast
  import os
  from typing import TYPE_CHECKING
  import pytest
  from airflow.models import DagBag
  from airflow.security import permissions
  from tests.test_utils.api_connexion_utils import assert_401, create_user, delete_user
  from tests.test_utils.db import clear_db_dag_code, clear_db_dags, clear_db_serialized_dags
label_desc: Use image node_id 1 for calling a global function with example usage: configured_app(minimal_app_for_api) without return types