Skip to content

Latest commit

 

History

History
29 lines (19 loc) · 1.07 KB

configuration.rst

File metadata and controls

29 lines (19 loc) · 1.07 KB

Configuration

asyncio_default_fixture_loop_scope

Determines the default event loop scope of asynchronous fixtures. When this configuration option is unset, it defaults to the fixture scope. In future versions of pytest-asyncio, the value will default to function when unset. Possible values are: function, class, module, package, session

asyncio_mode

The pytest-asyncio mode can be set by the asyncio_mode configuration option in the configuration file:

# pytest.ini
[pytest]
asyncio_mode = auto

The value can also be set via the --asyncio-mode command-line option:

$ pytest tests --asyncio-mode=strict

If the asyncio mode is set in both the pytest configuration file and the command-line option, the command-line option takes precedence. If no asyncio mode is specified, the mode defaults to strict.