Eric Pouech : dbghelp/tests: Add tests for SymRefreshModuleList() on non-live target.
Module: wine Branch: master Commit: 0f98972fe2165d5eca52de48d8a6130de7e61a30 URL: https://gitlab.winehq.org/wine/wine/-/commit/0f98972fe2165d5eca52de48d8a6130... Author: Eric Pouech <eric.pouech(a)gmail.com> Date: Wed Mar 8 11:43:22 2023 +0100 dbghelp/tests: Add tests for SymRefreshModuleList() on non-live target. Signed-off-by: Eric Pouech <eric.pouech(a)gmail.com> --- dlls/dbghelp/tests/dbghelp.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/dlls/dbghelp/tests/dbghelp.c b/dlls/dbghelp/tests/dbghelp.c index f6cea0125f4..445576532e6 100644 --- a/dlls/dbghelp/tests/dbghelp.c +++ b/dlls/dbghelp/tests/dbghelp.c @@ -424,6 +424,9 @@ static BOOL test_modules(void) ret = SymInitialize(dummy, NULL, FALSE); ok(ret, "got error %lu\n", GetLastError()); + ret = SymRefreshModuleList(dummy); + ok(!ret, "SymRefreshModuleList should have failed\n"); + count = get_module_count(dummy); ok(count == 0, "Unexpected count (%u instead of 0)\n", count); @@ -731,6 +734,10 @@ static void test_loaded_modules(void) } } + ret = SymRefreshModuleList(pi.hProcess); + todo_wine_if(get_process_kind(pi.hProcess) == PCSKIND_WOW64) + ok(ret || broken(GetLastError() == STATUS_PARTIAL_COPY /* Win11 in some cases */), "SymRefreshModuleList failed: %lu\n", GetLastError()); + SymCleanup(pi.hProcess); TerminateProcess(pi.hProcess, 0); @@ -766,6 +773,9 @@ static void test_loaded_modules(void) "Wrong directory aggregation count %u %u\n", aggregation.count_systemdir, aggregation.count_wowdir); + ret = SymRefreshModuleList(pi.hProcess); + ok(ret, "SymRefreshModuleList failed: %lu\n", GetLastError()); + SymCleanup(pi.hProcess); TerminateProcess(pi.hProcess, 0); } @@ -804,6 +814,9 @@ static void test_loaded_modules(void) "Wrong directory aggregation count %u %u\n", aggregation2.count_systemdir, aggregation2.count_wowdir); + ret = SymRefreshModuleList(pi.hProcess); + ok(ret, "SymRefreshModuleList failed: %lu\n", GetLastError()); + SymCleanup(pi.hProcess); TerminateProcess(pi.hProcess, 0); }
participants (1)
-
Alexandre Julliard