mirror of
https://github.com/reactos/reactos.git
synced 2025-02-22 16:36:33 +00:00
[SHELL32_APITEST] SHParseDisplayName: More tests for relative paths
This commit is contained in:
parent
53edadb8c0
commit
df88fcf5cc
1 changed files with 8 additions and 0 deletions
|
@ -46,7 +46,11 @@ struct test_data Tests[] =
|
|||
{__LINE__, L" :", NULL, 0, E_INVALIDARG, 0},
|
||||
{__LINE__, L"/", NULL, 0, E_INVALIDARG, 0},
|
||||
{__LINE__, L"//", NULL, 0, E_INVALIDARG, 0},
|
||||
/* This opens C:\ from Win+R and address bar */
|
||||
{__LINE__, L"\\", NULL, 0, E_INVALIDARG, 0},
|
||||
/* These two opens "C:\Program Files" from Win+R and address bar */
|
||||
{__LINE__, L"\\Program Files", NULL, 0, E_INVALIDARG, 0},
|
||||
{__LINE__, L"\\Program Files\\", NULL, 0, E_INVALIDARG, 0},
|
||||
{__LINE__, L"\\\\?", NULL, 0, E_INVALIDARG, 0},
|
||||
{__LINE__, L"\\\\?\\", NULL, 0, E_INVALIDARG, 0},
|
||||
/* Tests for the shell: protocol */
|
||||
|
@ -139,6 +143,7 @@ UINT get_host_os_flag()
|
|||
START_TEST(SHParseDisplayName)
|
||||
{
|
||||
HRESULT hr;
|
||||
WCHAR winDir[MAX_PATH];
|
||||
UINT os_flag = get_host_os_flag();
|
||||
ok (os_flag != 0, "Incompatible os version %d!", os_flag);
|
||||
if (os_flag == 0)
|
||||
|
@ -148,6 +153,9 @@ START_TEST(SHParseDisplayName)
|
|||
hr = SHGetDesktopFolder(&psfDesktop);
|
||||
ok(hr == S_OK, "hr = %lx\n", hr);
|
||||
|
||||
GetWindowsDirectoryW(winDir, _countof(winDir));
|
||||
SetCurrentDirectoryW(winDir);
|
||||
|
||||
for (UINT i = 0; i < _countof(Tests); i ++)
|
||||
{
|
||||
if (Tests[i].ValidForVersion && !(Tests[i].ValidForVersion & os_flag))
|
||||
|
|
Loading…
Reference in a new issue