mscms/tests: Skip tests if we don't have enough rights.
This commit is contained in:
parent
0653b95017
commit
35a10f05bc
|
@ -653,7 +653,13 @@ static void test_GetStandardColorSpaceProfileA(void)
|
||||||
ret = pGetStandardColorSpaceProfileA( NULL, SPACE_RGB, oldprofile, &size );
|
ret = pGetStandardColorSpaceProfileA( NULL, SPACE_RGB, oldprofile, &size );
|
||||||
ok( ret, "GetStandardColorSpaceProfileA() failed (%d)\n", GetLastError() );
|
ok( ret, "GetStandardColorSpaceProfileA() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
|
SetLastError(0xdeadbeef);
|
||||||
ret = pSetStandardColorSpaceProfileA( NULL, SPACE_RGB, standardprofile );
|
ret = pSetStandardColorSpaceProfileA( NULL, SPACE_RGB, standardprofile );
|
||||||
|
if (!ret && (GetLastError() == ERROR_ACCESS_DENIED))
|
||||||
|
{
|
||||||
|
skip("Not enough rights for SetStandardColorSpaceProfileA\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
ok( ret, "SetStandardColorSpaceProfileA() failed (%d)\n", GetLastError() );
|
ok( ret, "SetStandardColorSpaceProfileA() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
size = sizeof(newprofile);
|
size = sizeof(newprofile);
|
||||||
|
@ -730,7 +736,13 @@ static void test_GetStandardColorSpaceProfileW(void)
|
||||||
ret = pGetStandardColorSpaceProfileW( NULL, SPACE_RGB, oldprofile, &size );
|
ret = pGetStandardColorSpaceProfileW( NULL, SPACE_RGB, oldprofile, &size );
|
||||||
ok( ret, "GetStandardColorSpaceProfileW() failed (%d)\n", GetLastError() );
|
ok( ret, "GetStandardColorSpaceProfileW() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
|
SetLastError(0xdeadbeef);
|
||||||
ret = pSetStandardColorSpaceProfileW( NULL, SPACE_RGB, standardprofileW );
|
ret = pSetStandardColorSpaceProfileW( NULL, SPACE_RGB, standardprofileW );
|
||||||
|
if (!ret && (GetLastError() == ERROR_ACCESS_DENIED))
|
||||||
|
{
|
||||||
|
skip("Not enough rights for SetStandardColorSpaceProfileW\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
ok( ret, "SetStandardColorSpaceProfileW() failed (%d)\n", GetLastError() );
|
ok( ret, "SetStandardColorSpaceProfileW() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
size = sizeof(newprofile);
|
size = sizeof(newprofile);
|
||||||
|
@ -871,7 +883,13 @@ static void test_InstallColorProfileA(void)
|
||||||
CHAR slash[] = "\\";
|
CHAR slash[] = "\\";
|
||||||
HANDLE handle;
|
HANDLE handle;
|
||||||
|
|
||||||
|
SetLastError(0xdeadbeef);
|
||||||
ret = pInstallColorProfileA( NULL, testprofile );
|
ret = pInstallColorProfileA( NULL, testprofile );
|
||||||
|
if (!ret && (GetLastError() == ERROR_ACCESS_DENIED))
|
||||||
|
{
|
||||||
|
skip("Not enough rights for InstallColorProfileA\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
ok( ret, "InstallColorProfileA() failed (%d)\n", GetLastError() );
|
ok( ret, "InstallColorProfileA() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
ret = pGetColorDirectoryA( NULL, dest, &size );
|
ret = pGetColorDirectoryA( NULL, dest, &size );
|
||||||
|
@ -922,7 +940,13 @@ static void test_InstallColorProfileW(void)
|
||||||
WCHAR slash[] = { '\\', 0 };
|
WCHAR slash[] = { '\\', 0 };
|
||||||
HANDLE handle;
|
HANDLE handle;
|
||||||
|
|
||||||
|
SetLastError(0xdeadbeef);
|
||||||
ret = pInstallColorProfileW( NULL, testprofileW );
|
ret = pInstallColorProfileW( NULL, testprofileW );
|
||||||
|
if (!ret && (GetLastError() == ERROR_ACCESS_DENIED))
|
||||||
|
{
|
||||||
|
skip("Not enough rights for InstallColorProfileW\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
ok( ret, "InstallColorProfileW() failed (%d)\n", GetLastError() );
|
ok( ret, "InstallColorProfileW() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
ret = pGetColorDirectoryW( NULL, dest, &size );
|
ret = pGetColorDirectoryW( NULL, dest, &size );
|
||||||
|
@ -1237,7 +1261,13 @@ static void test_UninstallColorProfileA(void)
|
||||||
CHAR slash[] = "\\";
|
CHAR slash[] = "\\";
|
||||||
HANDLE handle;
|
HANDLE handle;
|
||||||
|
|
||||||
|
SetLastError(0xdeadbeef);
|
||||||
ret = pInstallColorProfileA( NULL, testprofile );
|
ret = pInstallColorProfileA( NULL, testprofile );
|
||||||
|
if (!ret && (GetLastError() == ERROR_ACCESS_DENIED))
|
||||||
|
{
|
||||||
|
skip("Not enough rights for InstallColorProfileA\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
ok( ret, "InstallColorProfileA() failed (%d)\n", GetLastError() );
|
ok( ret, "InstallColorProfileA() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
ret = pGetColorDirectoryA( NULL, dest, &size );
|
ret = pGetColorDirectoryA( NULL, dest, &size );
|
||||||
|
@ -1281,7 +1311,13 @@ static void test_UninstallColorProfileW(void)
|
||||||
HANDLE handle;
|
HANDLE handle;
|
||||||
int bytes_copied;
|
int bytes_copied;
|
||||||
|
|
||||||
|
SetLastError(0xdeadbeef);
|
||||||
ret = pInstallColorProfileW( NULL, testprofileW );
|
ret = pInstallColorProfileW( NULL, testprofileW );
|
||||||
|
if (!ret && (GetLastError() == ERROR_ACCESS_DENIED))
|
||||||
|
{
|
||||||
|
skip("Not enough rights for InstallColorProfileW\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
ok( ret, "InstallColorProfileW() failed (%d)\n", GetLastError() );
|
ok( ret, "InstallColorProfileW() failed (%d)\n", GetLastError() );
|
||||||
|
|
||||||
ret = pGetColorDirectoryW( NULL, dest, &size );
|
ret = pGetColorDirectoryW( NULL, dest, &size );
|
||||||
|
|
Loading…
Reference in New Issue