Jinoh Kang (@iamahuman) commented about dlls/windows.media.speech/tests/speech.c:
+ IAsyncAction_Release(action); + + recog_state = 0xdeadbeef; + hr = ISpeechRecognizer2_get_State(recognizer2, &recog_state); + ok(hr == S_OK, "ISpeechRecognizer2_get_State failed, hr %#lx.\n", hr); + ok(recog_state == SpeechRecognizerState_Idle, "recog_state was %u.\n", recog_state); + + hr = ISpeechContinuousRecognitionSession_StartAsync(session, &action); + ok(hr == S_OK, "ISpeechContinuousRecognitionSession_PauseAsync failed, hr %#lx.\n", hr); + await_async_void(action, &action_handler); + IAsyncAction_Release(action); + + recog_state = 0xdeadbeef; + hr = ISpeechRecognizer2_get_State(recognizer2, &recog_state); + ok(hr == S_OK, "ISpeechRecognizer2_get_State failed, hr %#lx.\n", hr); + ok(recog_state == SpeechRecognizerState_Capturing, "recog_state was %u.\n", recog_state); Looks like Windows might not immediately enter the capturing state.
```suggestion:-0+0 ok(recog_state == SpeechRecognizerState_Capturing || recog_state == SpeechRecognizerState_Idle, "recog_state was %u.\n", recog_state); ``` Alternatively, loop a few times with sleep and timeout until it is no longer idle? -- https://gitlab.winehq.org/wine/wine/-/merge_requests/1948#note_21970