Commit 64c13539 authored by Hans Leidekker's avatar Hans Leidekker Committed by Alexandre Julliard

mstask/tests: Skip ITaskScheduler::SetTargetComputer tests if the user doesn't have admin rights.

parent ea7c86a7
......@@ -184,6 +184,11 @@ static void test_SetTargetComputer(void)
/* the two backslashes are optional */
hres = ITaskScheduler_SetTargetComputer(test_task_scheduler, oldname + 2);
if (hres == E_ACCESSDENIED)
{
skip("SetTargetComputer failed with E_ACCESSDENIED (needs admin rights)\n");
goto done;
}
ok(hres == S_OK, "got 0x%x (expected S_OK)\n", hres);
/* the case is ignored */
......@@ -198,6 +203,7 @@ static void test_SetTargetComputer(void)
hres = ITaskScheduler_SetTargetComputer(test_task_scheduler, oldname);
ok(hres == S_OK, "got 0x%x (expected S_OK)\n", hres);
done:
CoTaskMemFree(oldname);
ITaskScheduler_Release(test_task_scheduler);
return;
......
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