From: Conor McCarthy cmccarthy@codeweavers.com
This test would hang if added before the regression fix. --- dlls/mf/tests/mf.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/dlls/mf/tests/mf.c b/dlls/mf/tests/mf.c index 73526802b63..faf82f676db 100644 --- a/dlls/mf/tests/mf.c +++ b/dlls/mf/tests/mf.c @@ -6453,6 +6453,7 @@ static void test_media_session_source_shutdown(void) HRESULT hr; enum { + TEST_TOPOLOGY, TEST_START, TEST_RESTART, TEST_PAUSE, @@ -6465,7 +6466,7 @@ static void test_media_session_source_shutdown(void)
/* These tests don't cover asynchronous shutdown, which is difficult to consistently test. */
- for (shutdown_point = TEST_START; shutdown_point <= TEST_CLOSE; ++shutdown_point) + for (shutdown_point = TEST_TOPOLOGY; shutdown_point <= TEST_CLOSE; ++shutdown_point) { winetest_push_context("Test %d", shutdown_point);
@@ -6489,6 +6490,8 @@ static void test_media_session_source_shutdown(void) hr = MFCreateMediaSession(NULL, &session); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); topology = create_test_topology(source, sink_activate, &duration); + if (shutdown_point == TEST_TOPOLOGY) + IMFMediaSource_Shutdown(source); hr = IMFMediaSession_SetTopology(session, 0, topology); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); IMFTopology_Release(topology); @@ -6501,7 +6504,7 @@ static void test_media_session_source_shutdown(void) IMFMediaSource_Shutdown(source); ok(hr == S_OK, "Unexpected hr %#lx.\n", hr); hr = wait_media_event(session, callback, MESessionStarted, 5000, &propvar); - ok(hr == (shutdown_point == TEST_START ? MF_E_INVALIDREQUEST : S_OK), "Unexpected hr %#lx.\n", hr); + ok(hr == (shutdown_point <= TEST_START ? MF_E_INVALIDREQUEST : S_OK), "Unexpected hr %#lx.\n", hr);
switch (shutdown_point) {