Skip to content

Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.

test(realtime): mock set_voice_mode in realtime_switch persist test

Ruben Lütkedf3c14890327
diff --git a/tests/unit/web/test_realtime_provider_category.py b/tests/unit/web/test_realtime_provider_category.py
index 9293b281b2..996329fe4d 100644
--- a/tests/unit/web/test_realtime_provider_category.py
+++ b/tests/unit/web/test_realtime_provider_category.py
@@ -84,6 +84,9 @@ def test_realtime_switch_persists_with_key(monkeypatch):
monkeypatch.setattr(
config_writer, "set_realtime_provider", lambda name, **kw: writes.append(name)
)
+ # Feature A4 also flips [voice].mode inside this route; mock it too so the
+ # test never touches the real jarvis.toml (isolation defect otherwise).
+ monkeypatch.setattr(config_writer, "set_voice_mode", lambda mode, **kw: None)
app = _app()
client = TestClient(app)