fix(telegram): separate voice transcription client (#166)

This commit is contained in:
codyw912
2026-01-17 14:50:08 -05:00
committed by GitHub
parent 9d7c6fcd8c
commit ee365d76ff
12 changed files with 83 additions and 15 deletions
+17
View File
@@ -135,6 +135,23 @@ def test_doctor_voice_checks(monkeypatch) -> None:
monkeypatch.delenv("OPENAI_API_KEY", raising=False)
checks = cli._doctor_voice_checks(settings)
assert checks[0].status == "error"
assert checks[0].detail == "API key not set"
settings_with_key = _settings(
{
"transports": {
"telegram": {
"bot_token": "token",
"chat_id": 1,
"voice_transcription": True,
"voice_transcription_api_key": "local",
}
}
}
)
checks = cli._doctor_voice_checks(settings_with_key)
assert checks[0].status == "ok"
assert checks[0].detail == "voice_transcription_api_key set"
monkeypatch.setenv("OPENAI_API_KEY", "key")
checks = cli._doctor_voice_checks(settings)