-
-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Description
Can we add support to use the pytest.fixture name parameter, if defined? Currently, the fixture is displayed with the fixture's function name. However, as described by pytest
:
Parameter
name
: This defaults to the name of the decorated function. If a fixture is used in the same module in which it is defined, the function name of the fixture will be shadowed by the function arg that requests the fixture; one way to resolve this is to name the decorated function fixture_ and then use @pytest.fixture(name='').
@pytest.fixture(name="myfixture", scope="session")
async def fixture_myfixture():
...
It could display the name either in the signature line, or at least if name
is diff than the function name, display above Scope
below the signature line?
Version
- Operating System:
- Python: 3.10
- sphinx-autofixture: 0.4.1
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request