From 4d24132ea4a6887c39f84935702af2c274f2a7a2 Mon Sep 17 00:00:00 2001 From: Francois Gouget Date: Mon, 13 Aug 2012 00:16:13 +0200 Subject: [PATCH] dsound/tests: Trace the number of tested DirectSound drivers. --- dlls/dsound/tests/ds3d.c | 4 ++++ dlls/dsound/tests/ds3d8.c | 4 ++++ dlls/dsound/tests/propset.c | 4 ++++ 3 files changed, 12 insertions(+) diff --git a/dlls/dsound/tests/ds3d.c b/dlls/dsound/tests/ds3d.c index dc25f256df5..36e59c900b4 100644 --- a/dlls/dsound/tests/ds3d.c +++ b/dlls/dsound/tests/ds3d.c @@ -1258,11 +1258,14 @@ return DSERR_GENERIC; return rc; } +static unsigned driver_count = 0; + static BOOL WINAPI dsenum_callback(LPGUID lpGuid, LPCSTR lpcstrDescription, LPCSTR lpcstrModule, LPVOID lpContext) { HRESULT rc; trace("*** Testing %s - %s ***\n",lpcstrDescription,lpcstrModule); + driver_count++; rc = test_for_driver(lpGuid); if (rc == DSERR_NODRIVER) { @@ -1309,6 +1312,7 @@ static void ds3d_tests(void) HRESULT rc; rc=pDirectSoundEnumerateA(&dsenum_callback,NULL); ok(rc==DS_OK,"DirectSoundEnumerateA() failed: %08x\n",rc); + trace("tested %u DirectSound drivers\n", driver_count); } START_TEST(ds3d) diff --git a/dlls/dsound/tests/ds3d8.c b/dlls/dsound/tests/ds3d8.c index e90057dc7c5..c432d356731 100644 --- a/dlls/dsound/tests/ds3d8.c +++ b/dlls/dsound/tests/ds3d8.c @@ -1081,11 +1081,14 @@ return DSERR_GENERIC; return rc; } +static unsigned driver_count = 0; + static BOOL WINAPI dsenum_callback(LPGUID lpGuid, LPCSTR lpcstrDescription, LPCSTR lpcstrModule, LPVOID lpContext) { HRESULT rc; trace("*** Testing %s - %s ***\n",lpcstrDescription,lpcstrModule); + driver_count++; rc = test_for_driver8(lpGuid); if (rc == DSERR_NODRIVER) { @@ -1132,6 +1135,7 @@ static void ds3d8_tests(void) HRESULT rc; rc=pDirectSoundEnumerateA(&dsenum_callback,NULL); ok(rc==DS_OK,"DirectSoundEnumerateA() failed: %08x\n",rc); + trace("tested %u DirectSound drivers\n", driver_count); } START_TEST(ds3d8) diff --git a/dlls/dsound/tests/propset.c b/dlls/dsound/tests/propset.c index e85924dbed6..6324a3f166f 100644 --- a/dlls/dsound/tests/propset.c +++ b/dlls/dsound/tests/propset.c @@ -553,6 +553,8 @@ static void propset_private_tests(void) IKsPropertySet_Release(pps); } +static unsigned driver_count = 0; + static BOOL WINAPI dsenum_callback(LPGUID lpGuid, LPCSTR lpcstrDescription, LPCSTR lpcstrModule, LPVOID lpContext) { @@ -564,6 +566,7 @@ static BOOL WINAPI dsenum_callback(LPGUID lpGuid, LPCSTR lpcstrDescription, int ref; trace("*** Testing %s - %s ***\n",lpcstrDescription,lpcstrModule); + driver_count++; rc=pDirectSoundCreate(lpGuid,&dso,NULL); ok(rc==DS_OK||rc==DSERR_NODRIVER||rc==DSERR_ALLOCATED||rc==E_FAIL, @@ -710,6 +713,7 @@ static void propset_buffer_tests(void) HRESULT rc; rc=pDirectSoundEnumerateA(&dsenum_callback,NULL); ok(rc==DS_OK,"DirectSoundEnumerateA() failed: %08x\n",rc); + trace("tested %u DirectSound drivers\n", driver_count); } START_TEST(propset)