mirror of
https://github.com/d3vyce/fastapi-toolsets.git
synced 2026-03-02 01:10:47 +01:00
28 lines
645 B
Python
28 lines
645 B
Python
from .fixtures import (
|
|
Context,
|
|
FixtureRegistry,
|
|
LoadStrategy,
|
|
load_fixtures,
|
|
load_fixtures_by_context,
|
|
)
|
|
from .utils import get_obj_by_attr
|
|
|
|
__all__ = [
|
|
"Context",
|
|
"FixtureRegistry",
|
|
"LoadStrategy",
|
|
"get_obj_by_attr",
|
|
"load_fixtures",
|
|
"load_fixtures_by_context",
|
|
"register_fixtures",
|
|
]
|
|
|
|
|
|
# We lazy-load register_fixtures to avoid needing pytest when using fixtures CLI
|
|
def __getattr__(name: str):
|
|
if name == "register_fixtures":
|
|
from .pytest_plugin import register_fixtures
|
|
|
|
return register_fixtures
|
|
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
|