Use in-memory channel layers in tests

This commit is contained in:
shamoon
2026-02-17 15:56:38 -08:00
parent 79687339d9
commit 14a250e388

11
src/conftest.py Normal file
View File

@@ -0,0 +1,11 @@
import pytest
from pytest_django.fixtures import SettingsWrapper
@pytest.fixture(autouse=True)
def in_memory_channel_layers(settings: SettingsWrapper) -> None:
settings.CHANNEL_LAYERS = {
"default": {
"BACKEND": "channels.layers.InMemoryChannelLayer",
},
}