Module: wine Branch: master Commit: 9523dec573c16497591b4b156ff4366078e16247 URL: https://gitlab.winehq.org/wine/wine/-/commit/9523dec573c16497591b4b156ff4366...
Author: Rémi Bernon rbernon@codeweavers.com Date: Thu Sep 7 15:29:00 2023 +0200
dinput/tests: Report the driver success and skipped tests counters.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=55535
---
dlls/dinput/tests/driver_hid.h | 6 ++++++ dlls/dinput/tests/hid.c | 3 +++ 2 files changed, 9 insertions(+)
diff --git a/dlls/dinput/tests/driver_hid.h b/dlls/dinput/tests/driver_hid.h index 291cf8963c2..ee5d26cdbf7 100644 --- a/dlls/dinput/tests/driver_hid.h +++ b/dlls/dinput/tests/driver_hid.h @@ -98,8 +98,11 @@ struct winetest_shared_data int running_under_wine; int winetest_report_success; int winetest_debug; + LONG successes; LONG failures; + LONG todo_successes; LONG todo_failures; + LONG skipped; };
static inline const char *debugstr_pnp( ULONG code ) @@ -339,8 +342,11 @@ static inline void winetest_cleanup_( const char *file ) { data = addr;
+ InterlockedExchangeAdd( &data->successes, winetest_successes ); InterlockedExchangeAdd( &data->failures, winetest_failures ); + InterlockedExchangeAdd( &data->todo_successes, winetest_todo_successes ); InterlockedExchangeAdd( &data->todo_failures, winetest_todo_failures ); + InterlockedExchangeAdd( &data->skipped, winetest_skipped );
ZwUnmapViewOfSection( NtCurrentProcess(), addr ); } diff --git a/dlls/dinput/tests/hid.c b/dlls/dinput/tests/hid.c index 9a27f8e93ac..0a28fda6f99 100644 --- a/dlls/dinput/tests/hid.c +++ b/dlls/dinput/tests/hid.c @@ -520,8 +520,11 @@ void bus_device_stop(void) SetFilePointer( okfile, 0, NULL, FILE_BEGIN ); SetEndOfFile( okfile );
+ InterlockedAdd( &winetest_successes, InterlockedExchange( &test_data->successes, 0 ) ); winetest_add_failures( InterlockedExchange( &test_data->failures, 0 ) ); + InterlockedAdd( &winetest_todo_successes, InterlockedExchange( &test_data->todo_successes, 0 ) ); winetest_add_failures( InterlockedExchange( &test_data->todo_failures, 0 ) ); + InterlockedAdd( &winetest_skipped, InterlockedExchange( &test_data->skipped, 0 ) );
GetFullPathNameW( L"winetest.inf", ARRAY_SIZE(path), path, NULL ); ret = SetupCopyOEMInfW( path, NULL, 0, 0, dest, ARRAY_SIZE(dest), NULL, &filepart );