kernel32/tests: Correctly skip tests when the Unicode directory functions are not available.
This commit is contained in:
parent
77fa32a832
commit
4f7f110c5e
|
@ -62,7 +62,10 @@ static void test_GetWindowsDirectoryW(void)
|
|||
|
||||
len_with_null = GetWindowsDirectoryW(NULL, 0);
|
||||
if (len_with_null == 0 && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED)
|
||||
{
|
||||
win_skip("GetWindowsDirectoryW is not implemented\n");
|
||||
return;
|
||||
}
|
||||
ok(len_with_null <= MAX_PATH, "should fit into MAX_PATH\n");
|
||||
|
||||
lstrcpyW(buf, fooW);
|
||||
|
@ -125,7 +128,10 @@ static void test_GetSystemDirectoryW(void)
|
|||
|
||||
len_with_null = GetSystemDirectoryW(NULL, 0);
|
||||
if (len_with_null == 0 && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED)
|
||||
{
|
||||
win_skip("GetSystemDirectoryW is not available\n");
|
||||
return;
|
||||
}
|
||||
ok(len_with_null <= MAX_PATH, "should fit into MAX_PATH\n");
|
||||
|
||||
lstrcpyW(buf, fooW);
|
||||
|
@ -338,7 +344,10 @@ static void test_CreateDirectoryW(void)
|
|||
|
||||
ret = CreateDirectoryW(NULL, NULL);
|
||||
if (!ret && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED)
|
||||
{
|
||||
win_skip("CreateDirectoryW is not available\n");
|
||||
return;
|
||||
}
|
||||
ok(ret == FALSE && GetLastError() == ERROR_PATH_NOT_FOUND,
|
||||
"should not create NULL path ret %u err %u\n", ret, GetLastError());
|
||||
|
||||
|
@ -442,7 +451,10 @@ static void test_RemoveDirectoryW(void)
|
|||
lstrcatW(tmpdir, tmp_dir_name);
|
||||
ret = CreateDirectoryW(tmpdir, NULL);
|
||||
if (!ret && GetLastError() == ERROR_CALL_NOT_IMPLEMENTED)
|
||||
{
|
||||
win_skip("CreateDirectoryW is not available\n");
|
||||
return;
|
||||
}
|
||||
|
||||
ok(ret == TRUE, "CreateDirectoryW should always succeed\n");
|
||||
|
||||
|
|
Loading…
Reference in New Issue