Home / File/ test_main_b.py — fastapi Source File

test_main_b.py — fastapi Source File

Architecture documentation for test_main_b.py, a python file in the fastapi codebase. 4 imports, 0 dependents.

File python FastAPI Applications 4 imports 2 functions

Entity Profile

Dependency Diagram

graph LR
  8128d1ba_fc56_6f85_e20d_67296f415537["test_main_b.py"]
  6c1c06f4_669c_bf0b_7578_edfc31f80c75["utils"]
  8128d1ba_fc56_6f85_e20d_67296f415537 --> 6c1c06f4_669c_bf0b_7578_edfc31f80c75
  83e01a9c_50a9_bec9_6f86_8e729106de01["importlib"]
  8128d1ba_fc56_6f85_e20d_67296f415537 --> 83e01a9c_50a9_bec9_6f86_8e729106de01
  fb2d9376_ca24_f2b2_f130_cc10e9f2e732["types"]
  8128d1ba_fc56_6f85_e20d_67296f415537 --> fb2d9376_ca24_f2b2_f130_cc10e9f2e732
  5befe8bf_65d1_d058_6b78_4a597a8488e9["pytest"]
  8128d1ba_fc56_6f85_e20d_67296f415537 --> 5befe8bf_65d1_d058_6b78_4a597a8488e9
  style 8128d1ba_fc56_6f85_e20d_67296f415537 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import importlib
from types import ModuleType

import pytest

from ...utils import needs_py310


@pytest.fixture(
    name="test_module",
    params=[
        "app_b_py39.test_main",
        pytest.param("app_b_py310.test_main", marks=needs_py310),
        "app_b_an_py39.test_main",
        pytest.param("app_b_an_py310.test_main", marks=needs_py310),
    ],
)
def get_test_module(request: pytest.FixtureRequest) -> ModuleType:
    mod: ModuleType = importlib.import_module(f"docs_src.app_testing.{request.param}")
    return mod


def test_app(test_module: ModuleType):
    test_main = test_module
    test_main.test_create_existing_item()
    test_main.test_create_item()
    test_main.test_create_item_bad_token()
    test_main.test_read_nonexistent_item()
    test_main.test_read_item()
    test_main.test_read_item_bad_token()

Domain

Subdomains

Dependencies

  • importlib
  • pytest
  • types
  • utils

Frequently Asked Questions

What does test_main_b.py do?
test_main_b.py is a source file in the fastapi codebase, written in python. It belongs to the FastAPI domain, Applications subdomain.
What functions are defined in test_main_b.py?
test_main_b.py defines 2 function(s): get_test_module, test_app.
What does test_main_b.py depend on?
test_main_b.py imports 4 module(s): importlib, pytest, types, utils.
Where is test_main_b.py in the architecture?
test_main_b.py is located at tests/test_tutorial/test_testing/test_main_b.py (domain: FastAPI, subdomain: Applications, directory: tests/test_tutorial/test_testing).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free