Commit 2078afb9 authored by Francois Gouget's avatar Francois Gouget Committed by Alexandre Julliard

advapi32/tests: Skip some tests if the EventLog service crashed.

advapi32:eventlog crashes the EventLog service in some Windows versions so defend against that condition. Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=53461
parent 42bd3bb7
......@@ -2919,6 +2919,16 @@ static void test_EventLog(void)
ok(status.dwServiceType == SERVICE_WIN32_SHARE_PROCESS ||
status.dwServiceType == (SERVICE_WIN32_SHARE_PROCESS | SERVICE_WIN32_OWN_PROCESS) /* Win10 */,
"got %#lx\n", status.dwServiceType);
ok(status.dwServiceSpecificExitCode == 0, "got %#lx\n", status.dwServiceSpecificExitCode);
ok(status.dwCheckPoint == 0, "got %#lx\n", status.dwCheckPoint);
ok(status.dwWaitHint == 0, "got %#lx\n", status.dwWaitHint);
ok(status.dwServiceFlags == 0 || status.dwServiceFlags == SERVICE_RUNS_IN_SYSTEM_PROCESS /* XP */,
"got %#lx\n", status.dwServiceFlags);
if (status.dwCurrentState == SERVICE_STOPPED &&
status.dwWin32ExitCode == ERROR_PROCESS_ABORTED)
win_skip("EventLog crashed!\n");
else
{
ok(status.dwCurrentState == SERVICE_RUNNING, "got %#lx\n", status.dwCurrentState);
todo_wine
ok(status.dwControlsAccepted == SERVICE_ACCEPT_SHUTDOWN /* XP */ ||
......@@ -2926,12 +2936,8 @@ static void test_EventLog(void)
status.dwControlsAccepted == (SERVICE_ACCEPT_STOP | SERVICE_ACCEPT_TIMECHANGE | SERVICE_ACCEPT_SHUTDOWN),
"got %#lx\n", status.dwControlsAccepted);
ok(status.dwWin32ExitCode == 0, "got %#lx\n", status.dwWin32ExitCode);
ok(status.dwServiceSpecificExitCode == 0, "got %#lx\n", status.dwServiceSpecificExitCode);
ok(status.dwCheckPoint == 0, "got %#lx\n", status.dwCheckPoint);
ok(status.dwWaitHint == 0, "got %#lx\n", status.dwWaitHint);
ok(status.dwProcessId != 0, "got %#lx\n", status.dwProcessId);
ok(status.dwServiceFlags == 0 || status.dwServiceFlags == SERVICE_RUNS_IN_SYSTEM_PROCESS /* XP */,
"got %#lx\n", status.dwServiceFlags);
}
CloseServiceHandle(svc_handle);
CloseServiceHandle(scm_handle);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment