feat:语音对话优化
This commit is contained in:
@@ -103,9 +103,12 @@ func TestMiMoService_Recognize_EmptyChoices(t *testing.T) {
|
||||
defer srv.Close()
|
||||
|
||||
wav := makeValidWAV([]byte{0x00, 0x00})
|
||||
_, err := s.Recognize(context.Background(), wav, Options{})
|
||||
if err == nil {
|
||||
t.Fatal("expected error for empty choices")
|
||||
text, err := s.Recognize(context.Background(), wav, Options{})
|
||||
if err != nil {
|
||||
t.Fatalf("unexpected error for empty choices: %v", err)
|
||||
}
|
||||
if text != "" {
|
||||
t.Errorf("expected empty string for empty choices, got %q", text)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user