Module: wine Branch: master Commit: 0922deda9360259a8d1c374599e5ced80357d037 URL: http://source.winehq.org/git/wine.git/?a=commit;h=0922deda9360259a8d1c374599...
Author: Hans Leidekker hans@codeweavers.com Date: Mon Dec 19 11:38:51 2016 +0100
setupapi/tests: Skip SetupCopyOEMInfA tests if the user doesn't have admin rights.
Signed-off-by: Hans Leidekker hans@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/setupapi/tests/misc.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/dlls/setupapi/tests/misc.c b/dlls/setupapi/tests/misc.c index 04b2171..dbe684b 100644 --- a/dlls/setupapi/tests/misc.c +++ b/dlls/setupapi/tests/misc.c @@ -231,6 +231,11 @@ static void test_SetupCopyOEMInf(void) strcat(path, tmpfile); SetLastError(0xdeadbeef); res = pSetupCopyOEMInfA(path, NULL, SPOST_NONE, 0, NULL, 0, NULL, NULL); + if (!res && GetLastError() == ERROR_ACCESS_DENIED) + { + skip("SetupCopyOEMInfA() failed on insufficient permissions\n"); + return; + } ok(res == TRUE, "Expected TRUE, got %d\n", res); ok(GetLastError() == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", GetLastError()); ok(file_exists(path), "Expected source inf to exist\n"); @@ -792,7 +797,7 @@ static void test_SetupLogError(void) ret = SetupOpenLog(FALSE); if (!ret && GetLastError() == ERROR_ACCESS_DENIED) { - win_skip("SetupOpenLog() failed on insufficient permissions\n"); + skip("SetupOpenLog() failed on insufficient permissions\n"); return; } ok(ret, "SetupOpenLog failed, error %d\n", GetLastError());