MCPcopy Index your code
hub / github.com/nonebot/nonebot2 / test_get_driver

Function test_get_driver

tests/test_init.py:37–41  ·  view source on GitHub ↗
(monkeypatch: pytest.MonkeyPatch)

Source from the content-addressed store, hash-verified

35
36
37def test_get_driver(monkeypatch: pytest.MonkeyPatch):
38 with monkeypatch.context() as m:
39 m.setattr(nonebot, "_driver", None)
40 with pytest.raises(ValueError, match="initialized"):
41 get_driver()
42
43
44def test_get_asgi():

Callers

nothing calls this directly

Calls 1

get_driverFunction · 0.90

Tested by

no test coverage detected