Tests should not use wine/unicode.h.
This commit is contained in:
parent
59493b6c33
commit
23f9e358ad
|
@ -35,7 +35,6 @@
|
||||||
#include "winreg.h"
|
#include "winreg.h"
|
||||||
#include "winnls.h"
|
#include "winnls.h"
|
||||||
#include "wine/test.h"
|
#include "wine/test.h"
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "winternl.h"
|
#include "winternl.h"
|
||||||
|
|
||||||
#ifndef __WINE_WINTERNL_H
|
#ifndef __WINE_WINTERNL_H
|
||||||
|
@ -112,14 +111,14 @@ static DWORD RtlAtomTestThread(LPVOID Table)
|
||||||
ok(!res, "Failed with longenough buffer, retval: %lx\n", res);
|
ok(!res, "Failed with longenough buffer, retval: %lx\n", res);
|
||||||
ok(RefCount == 1, "Refcount was not 1 but %lx\n", RefCount);
|
ok(RefCount == 1, "Refcount was not 1 but %lx\n", RefCount);
|
||||||
ok(PinCount == 1, "Pincount was not 1 but %lx\n", PinCount);
|
ok(PinCount == 1, "Pincount was not 1 but %lx\n", PinCount);
|
||||||
ok(!strcmpW(Name, testAtom2), "We found wrong atom!!\n");
|
ok(!lstrcmpW(Name, testAtom2), "We found wrong atom!!\n");
|
||||||
ok((strlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
ok((lstrlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
||||||
|
|
||||||
Len = 64;
|
Len = 64;
|
||||||
res = pRtlQueryAtomInAtomTable(AtomTable, Atom, NULL, NULL, Name, &Len);
|
res = pRtlQueryAtomInAtomTable(AtomTable, Atom, NULL, NULL, Name, &Len);
|
||||||
ok(!res, "RtlQueryAtomInAtomTable with optional args invalid failed, retval: %lx\n", res);
|
ok(!res, "RtlQueryAtomInAtomTable with optional args invalid failed, retval: %lx\n", res);
|
||||||
ok(!strcmpW(Name, testAtom2), "Found Wrong atom!\n");
|
ok(!lstrcmpW(Name, testAtom2), "Found Wrong atom!\n");
|
||||||
ok((strlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
ok((lstrlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
||||||
|
|
||||||
res = pRtlPinAtomInAtomTable(AtomTable, Atom);
|
res = pRtlPinAtomInAtomTable(AtomTable, Atom);
|
||||||
ok(!res, "Unable to pin atom in atom table, retval: %lx\n", res);
|
ok(!res, "Unable to pin atom in atom table, retval: %lx\n", res);
|
||||||
|
@ -184,8 +183,8 @@ static void test_NtAtom(void)
|
||||||
ok(!res, "Unable to query atom in atom table, retval: %lx\n", res);
|
ok(!res, "Unable to query atom in atom table, retval: %lx\n", res);
|
||||||
ok(RefCount == 1, "RefCount is not 1 but %lx\n", RefCount);
|
ok(RefCount == 1, "RefCount is not 1 but %lx\n", RefCount);
|
||||||
ok(PinCount == 1, "PinCount is not 1 but %lx\n", PinCount);
|
ok(PinCount == 1, "PinCount is not 1 but %lx\n", PinCount);
|
||||||
ok(!strcmpW(Name, testAtom2), "We found wrong atom\n");
|
ok(!lstrcmpW(Name, testAtom2), "We found wrong atom\n");
|
||||||
ok((strlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
ok((lstrlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
||||||
|
|
||||||
res = pRtlEmptyAtomTable(AtomTable, FALSE);
|
res = pRtlEmptyAtomTable(AtomTable, FALSE);
|
||||||
ok(!res, "Unable to empty atom table, retval %lx\n", res);
|
ok(!res, "Unable to empty atom table, retval %lx\n", res);
|
||||||
|
@ -195,8 +194,8 @@ static void test_NtAtom(void)
|
||||||
ok(!res, "It seems RtlEmptyAtomTable deleted our pinned atom eaven though we asked it not to, retval: %lx\n", res);
|
ok(!res, "It seems RtlEmptyAtomTable deleted our pinned atom eaven though we asked it not to, retval: %lx\n", res);
|
||||||
ok(RefCount == 1, "RefCount is not 1 but %lx\n", RefCount);
|
ok(RefCount == 1, "RefCount is not 1 but %lx\n", RefCount);
|
||||||
ok(PinCount == 1, "PinCount is not 1 but %lx\n", PinCount);
|
ok(PinCount == 1, "PinCount is not 1 but %lx\n", PinCount);
|
||||||
ok(!strcmpW(Name, testAtom2), "We found wrong atom\n");
|
ok(!lstrcmpW(Name, testAtom2), "We found wrong atom\n");
|
||||||
ok((strlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
ok((lstrlenW(testAtom2) * sizeof(WCHAR)) == Len, "Returned wrong length %ld\n", Len);
|
||||||
|
|
||||||
Len = 8;
|
Len = 8;
|
||||||
Name[0] = Name[1] = Name[2] = Name[3] = Name[4] = 0x55AA;
|
Name[0] = Name[1] = Name[2] = Name[3] = Name[4] = 0x55AA;
|
||||||
|
@ -267,7 +266,7 @@ static void test_NtAtom(void)
|
||||||
Len = 0;
|
Len = 0;
|
||||||
res = pRtlQueryAtomInAtomTable(AtomTable, Atom1, NULL, NULL, Name, &Len);
|
res = pRtlQueryAtomInAtomTable(AtomTable, Atom1, NULL, NULL, Name, &Len);
|
||||||
ok(res == STATUS_BUFFER_TOO_SMALL, "Got wrong retval, retval: %lx\n", res);
|
ok(res == STATUS_BUFFER_TOO_SMALL, "Got wrong retval, retval: %lx\n", res);
|
||||||
ok((strlenW(testAtom1) * sizeof(WCHAR)) == Len, "Got wrong length %lx\n", Len);
|
ok((lstrlenW(testAtom1) * sizeof(WCHAR)) == Len, "Got wrong length %lx\n", Len);
|
||||||
|
|
||||||
res = pRtlPinAtomInAtomTable(AtomTable, Atom1);
|
res = pRtlPinAtomInAtomTable(AtomTable, Atom1);
|
||||||
ok(!res, "Unable to pin atom in atom table, retval: %lx\n", res);
|
ok(!res, "Unable to pin atom in atom table, retval: %lx\n", res);
|
||||||
|
@ -360,8 +359,8 @@ static void test_NtIntAtom(void)
|
||||||
ok(!res, "Unable to query atom in atom table, retval: %lx\n", res);
|
ok(!res, "Unable to query atom in atom table, retval: %lx\n", res);
|
||||||
ok(PinCount == 1, "Expected pincount 1 but got %lx\n", PinCount);
|
ok(PinCount == 1, "Expected pincount 1 but got %lx\n", PinCount);
|
||||||
ok(RefCount == 1, "Expected refcount 1 but got %lx\n", RefCount);
|
ok(RefCount == 1, "Expected refcount 1 but got %lx\n", RefCount);
|
||||||
ok(!strcmpW(testAtomOTT, Name), "Got wrong atom name\n");
|
ok(!lstrcmpW(testAtomOTT, Name), "Got wrong atom name\n");
|
||||||
ok((strlenW(testAtomOTT) * sizeof(WCHAR)) == Len, "Got wrong len %ld\n", Len);
|
ok((lstrlenW(testAtomOTT) * sizeof(WCHAR)) == Len, "Got wrong len %ld\n", Len);
|
||||||
|
|
||||||
res = pRtlPinAtomInAtomTable(AtomTable, testAtom);
|
res = pRtlPinAtomInAtomTable(AtomTable, testAtom);
|
||||||
ok(!res, "Unable to pin int atom, retval: %lx\n", res);
|
ok(!res, "Unable to pin int atom, retval: %lx\n", res);
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
#include "ntdll_test.h"
|
#include "ntdll_test.h"
|
||||||
#include "wine/unicode.h"
|
|
||||||
|
|
||||||
static NTSTATUS (WINAPI *pRtlMultiByteToUnicodeN)( LPWSTR dst, DWORD dstlen, LPDWORD reslen,
|
static NTSTATUS (WINAPI *pRtlMultiByteToUnicodeN)( LPWSTR dst, DWORD dstlen, LPDWORD reslen,
|
||||||
LPCSTR src, DWORD srclen );
|
LPCSTR src, DWORD srclen );
|
||||||
|
@ -108,8 +107,8 @@ static void testQuery(void)
|
||||||
pRtlMultiByteToUnicodeN( bn, sizeof(bn), NULL, test->val, strlen(test->val)+1 );
|
pRtlMultiByteToUnicodeN( bn, sizeof(bn), NULL, test->val, strlen(test->val)+1 );
|
||||||
ok( value.Length == strlen(test->val) * sizeof(WCHAR), "Wrong length %d/%d for %s\n",
|
ok( value.Length == strlen(test->val) * sizeof(WCHAR), "Wrong length %d/%d for %s\n",
|
||||||
value.Length, strlen(test->val) * sizeof(WCHAR), test->var );
|
value.Length, strlen(test->val) * sizeof(WCHAR), test->var );
|
||||||
ok((value.Length == strlen(test->val) * sizeof(WCHAR) && strncmpW(bv, bn, test->len) == 0) ||
|
ok((value.Length == strlen(test->val) * sizeof(WCHAR) && memcmp(bv, bn, test->len*sizeof(WCHAR)) == 0) ||
|
||||||
strcmpW(bv, bn) == 0,
|
lstrcmpW(bv, bn) == 0,
|
||||||
"Wrong result for %s/%d\n", test->var, test->len);
|
"Wrong result for %s/%d\n", test->var, test->len);
|
||||||
ok(bv[test->len] == '@', "Writing too far away in the buffer for %s/%d\n", test->var, test->len);
|
ok(bv[test->len] == '@', "Writing too far away in the buffer for %s/%d\n", test->var, test->len);
|
||||||
break;
|
break;
|
||||||
|
@ -151,7 +150,7 @@ static void testSetHelper(LPWSTR* env, const char* var, const char* val, NTSTATU
|
||||||
switch (nts)
|
switch (nts)
|
||||||
{
|
{
|
||||||
case STATUS_SUCCESS:
|
case STATUS_SUCCESS:
|
||||||
ok(strcmpW(bval1, bval2) == 0, "Cannot get value written to environment\n");
|
ok(lstrcmpW(bval1, bval2) == 0, "Cannot get value written to environment\n");
|
||||||
break;
|
break;
|
||||||
case STATUS_VARIABLE_NOT_FOUND:
|
case STATUS_VARIABLE_NOT_FOUND:
|
||||||
ok(val == NULL, "Couldn't find variable, but didn't delete it. val = %s\n", val);
|
ok(val == NULL, "Couldn't find variable, but didn't delete it. val = %s\n", val);
|
||||||
|
@ -257,7 +256,7 @@ static void testExpand(void)
|
||||||
ok(ul == strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR),
|
ok(ul == strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR),
|
||||||
"Wrong returned length for %s: %lu <> %u\n",
|
"Wrong returned length for %s: %lu <> %u\n",
|
||||||
test->src, ul, strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR));
|
test->src, ul, strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR));
|
||||||
ok(strcmpW(dst, rst) == 0, "Wrong result for %s: expecting %s\n",
|
ok(lstrcmpW(dst, rst) == 0, "Wrong result for %s: expecting %s\n",
|
||||||
test->src, test->dst);
|
test->src, test->dst);
|
||||||
|
|
||||||
us_dst.Length = 0;
|
us_dst.Length = 0;
|
||||||
|
@ -269,7 +268,7 @@ static void testExpand(void)
|
||||||
ok(ul == strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR),
|
ok(ul == strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR),
|
||||||
"Wrong returned length for %s (with buffer too small): %lu <> %u\n",
|
"Wrong returned length for %s (with buffer too small): %lu <> %u\n",
|
||||||
test->src, ul, strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR));
|
test->src, ul, strlen(test->dst) * sizeof(WCHAR) + sizeof(WCHAR));
|
||||||
ok(strncmpW(dst, rst, 8) == 0,
|
ok(memcmp(dst, rst, 8*sizeof(WCHAR)) == 0,
|
||||||
"Wrong result for %s (with buffer too small): expecting %s\n",
|
"Wrong result for %s (with buffer too small): expecting %s\n",
|
||||||
test->src, test->dst);
|
test->src, test->dst);
|
||||||
ok(dst[8] == '-', "Writing too far in buffer (got %c/%d)\n", dst[8], dst[8]);
|
ok(dst[8] == '-', "Writing too far in buffer (got %c/%d)\n", dst[8], dst[8]);
|
||||||
|
|
|
@ -28,7 +28,6 @@
|
||||||
#include "winreg.h"
|
#include "winreg.h"
|
||||||
#include "winnls.h"
|
#include "winnls.h"
|
||||||
#include "wine/test.h"
|
#include "wine/test.h"
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "winternl.h"
|
#include "winternl.h"
|
||||||
|
|
||||||
#ifndef __WINE_WINTERNL_H
|
#ifndef __WINE_WINTERNL_H
|
||||||
|
|
|
@ -19,7 +19,6 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "wine/test.h"
|
#include "wine/test.h"
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "oleauto.h"
|
#include "oleauto.h"
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
|
|
||||||
|
@ -3470,7 +3469,7 @@ static void test_VarDateChangeTypeEx(void)
|
||||||
|
|
||||||
hres = VariantChangeTypeEx(&vDst, &vSrc, lcid, VARIANT_NOUSEROVERRIDE, VT_BSTR);
|
hres = VariantChangeTypeEx(&vDst, &vSrc, lcid, VARIANT_NOUSEROVERRIDE, VT_BSTR);
|
||||||
ok(hres == S_OK && V_VT(&vDst) == VT_BSTR && V_BSTR(&vDst) &&
|
ok(hres == S_OK && V_VT(&vDst) == VT_BSTR && V_BSTR(&vDst) &&
|
||||||
(!strcmpW(V_BSTR(&vDst), sz25570) || !strcmpW(V_BSTR(&vDst), sz25570_2)),
|
(!lstrcmpW(V_BSTR(&vDst), sz25570) || !lstrcmpW(V_BSTR(&vDst), sz25570_2)),
|
||||||
"hres=0x%lX, type=%d (should be VT_BSTR), *bstr=%s\n",
|
"hres=0x%lX, type=%d (should be VT_BSTR), *bstr=%s\n",
|
||||||
hres, V_VT(&vDst), V_BSTR(&vDst) ? wtoascii(V_BSTR(&vDst)) : "?");
|
hres, V_VT(&vDst), V_BSTR(&vDst) ? wtoascii(V_BSTR(&vDst)) : "?");
|
||||||
|
|
||||||
|
@ -3478,7 +3477,7 @@ static void test_VarDateChangeTypeEx(void)
|
||||||
if (HAVE_OLEAUT32_LOCALES)
|
if (HAVE_OLEAUT32_LOCALES)
|
||||||
{
|
{
|
||||||
hres = VariantChangeTypeEx(&vDst, &vSrc, lcid, VARIANT_NOUSEROVERRIDE|VARIANT_USE_NLS, VT_BSTR);
|
hres = VariantChangeTypeEx(&vDst, &vSrc, lcid, VARIANT_NOUSEROVERRIDE|VARIANT_USE_NLS, VT_BSTR);
|
||||||
ok(hres == S_OK && V_VT(&vDst) == VT_BSTR && V_BSTR(&vDst) && !strcmpW(V_BSTR(&vDst), sz25570Nls),
|
ok(hres == S_OK && V_VT(&vDst) == VT_BSTR && V_BSTR(&vDst) && !lstrcmpW(V_BSTR(&vDst), sz25570Nls),
|
||||||
"hres=0x%lX, type=%d (should be VT_BSTR), *bstr=%s\n",
|
"hres=0x%lX, type=%d (should be VT_BSTR), *bstr=%s\n",
|
||||||
hres, V_VT(&vDst), V_BSTR(&vDst) ? wtoascii(V_BSTR(&vDst)) : "?");
|
hres, V_VT(&vDst), V_BSTR(&vDst) ? wtoascii(V_BSTR(&vDst)) : "?");
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
#include <winnt.h>
|
#include <winnt.h>
|
||||||
#include <winerror.h>
|
#include <winerror.h>
|
||||||
|
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "rpc.h"
|
#include "rpc.h"
|
||||||
#include "rpcdce.h"
|
#include "rpcdce.h"
|
||||||
#include "rpcproxy.h"
|
#include "rpcproxy.h"
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
#include <winnt.h>
|
#include <winnt.h>
|
||||||
#include <winerror.h>
|
#include <winerror.h>
|
||||||
|
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "rpc.h"
|
#include "rpc.h"
|
||||||
#include "rpcdce.h"
|
#include "rpcdce.h"
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,6 @@
|
||||||
#include "shlguid.h"
|
#include "shlguid.h"
|
||||||
#include "ole2.h"
|
#include "ole2.h"
|
||||||
|
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "wine/test.h"
|
#include "wine/test.h"
|
||||||
|
|
||||||
/* The following definitions and helper functions are meant to make the de-/registration
|
/* The following definitions and helper functions are meant to make the de-/registration
|
||||||
|
|
|
@ -36,8 +36,6 @@
|
||||||
#include "ocidl.h"
|
#include "ocidl.h"
|
||||||
#include "oleauto.h"
|
#include "oleauto.h"
|
||||||
|
|
||||||
|
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "wine/test.h"
|
#include "wine/test.h"
|
||||||
|
|
||||||
|
|
||||||
|
@ -727,8 +725,8 @@ static void test_GetAttributesOf(void)
|
||||||
IMalloc_Free(ppM, newPIDL);
|
IMalloc_Free(ppM, newPIDL);
|
||||||
|
|
||||||
/* append testdirectory name to path */
|
/* append testdirectory name to path */
|
||||||
strcatW(cCurrDirW, cBackSlash);
|
lstrcatW(cCurrDirW, cBackSlash);
|
||||||
strcatW(cCurrDirW, cTestDirW);
|
lstrcatW(cCurrDirW, cTestDirW);
|
||||||
|
|
||||||
hr = IShellFolder_ParseDisplayName(IDesktopFolder, NULL, NULL, cCurrDirW, NULL, &newPIDL, 0);
|
hr = IShellFolder_ParseDisplayName(IDesktopFolder, NULL, NULL, cCurrDirW, NULL, &newPIDL, 0);
|
||||||
ok(hr == S_OK, "ParseDisplayName failed %08lx\n", hr);
|
ok(hr == S_OK, "ParseDisplayName failed %08lx\n", hr);
|
||||||
|
@ -890,7 +888,7 @@ static void test_EnumObjects_and_CompareIDs(void)
|
||||||
cCurrDirA[len-1] = 0;
|
cCurrDirA[len-1] = 0;
|
||||||
|
|
||||||
MultiByteToWideChar(CP_ACP, 0, cCurrDirA, -1, cCurrDirW, MAX_PATH);
|
MultiByteToWideChar(CP_ACP, 0, cCurrDirA, -1, cCurrDirW, MAX_PATH);
|
||||||
strcatW(cCurrDirW, cTestDirW);
|
lstrcatW(cCurrDirW, cTestDirW);
|
||||||
|
|
||||||
hr = SHGetDesktopFolder(&IDesktopFolder);
|
hr = SHGetDesktopFolder(&IDesktopFolder);
|
||||||
ok(hr == S_OK, "SHGetDesktopfolder failed %08lx\n", hr);
|
ok(hr == S_OK, "SHGetDesktopfolder failed %08lx\n", hr);
|
||||||
|
|
|
@ -24,7 +24,6 @@
|
||||||
#include "wine/test.h"
|
#include "wine/test.h"
|
||||||
#include "windef.h"
|
#include "windef.h"
|
||||||
#include "winbase.h"
|
#include "winbase.h"
|
||||||
#include "wine/unicode.h"
|
|
||||||
#include "winreg.h"
|
#include "winreg.h"
|
||||||
#include "shlwapi.h"
|
#include "shlwapi.h"
|
||||||
#include "wininet.h"
|
#include "wininet.h"
|
||||||
|
@ -352,7 +351,7 @@ static void test_url_part(const char* szUrl, DWORD dwPart, DWORD dwFlags, const
|
||||||
|
|
||||||
wszConvertedPart = GetWideString(szPart);
|
wszConvertedPart = GetWideString(szPart);
|
||||||
|
|
||||||
ok(strcmpW(wszPart,wszConvertedPart)==0, "Strings didn't match between ascii and unicode UrlGetPart!\n");
|
ok(lstrcmpW(wszPart,wszConvertedPart)==0, "Strings didn't match between ascii and unicode UrlGetPart!\n");
|
||||||
|
|
||||||
FreeWideString(wszUrl);
|
FreeWideString(wszUrl);
|
||||||
FreeWideString(wszConvertedPart);
|
FreeWideString(wszConvertedPart);
|
||||||
|
@ -389,7 +388,7 @@ static void test_url_escape(const char *szUrl, DWORD dwFlags, HRESULT dwExpectRe
|
||||||
expected_urlW = GetWideString(szExpectUrl);
|
expected_urlW = GetWideString(szExpectUrl);
|
||||||
ok(UrlEscapeW(urlW, ret_urlW, &dwEscaped, dwFlags) == dwExpectReturn, "UrlEscapeW didn't return 0x%08lx from \"%s\"\n", dwExpectReturn, szUrl);
|
ok(UrlEscapeW(urlW, ret_urlW, &dwEscaped, dwFlags) == dwExpectReturn, "UrlEscapeW didn't return 0x%08lx from \"%s\"\n", dwExpectReturn, szUrl);
|
||||||
WideCharToMultiByte(CP_ACP,0,ret_urlW,-1,szReturnUrl,INTERNET_MAX_URL_LENGTH,0,0);
|
WideCharToMultiByte(CP_ACP,0,ret_urlW,-1,szReturnUrl,INTERNET_MAX_URL_LENGTH,0,0);
|
||||||
ok(strcmpW(ret_urlW, expected_urlW)==0, "Expected \"%s\", but got \"%s\" from \"%s\" flags %08lx\n", szExpectUrl, szReturnUrl, szUrl, dwFlags);
|
ok(lstrcmpW(ret_urlW, expected_urlW)==0, "Expected \"%s\", but got \"%s\" from \"%s\" flags %08lx\n", szExpectUrl, szReturnUrl, szUrl, dwFlags);
|
||||||
FreeWideString(urlW);
|
FreeWideString(urlW);
|
||||||
FreeWideString(expected_urlW);
|
FreeWideString(expected_urlW);
|
||||||
|
|
||||||
|
@ -414,7 +413,7 @@ static void test_url_canonicalize(const char *szUrl, DWORD dwFlags, HRESULT dwEx
|
||||||
ok(UrlCanonicalizeW(wszUrl, NULL, &dwSize, dwFlags) != dwExpectReturn, "Unexpected return for NULL buffer\n");
|
ok(UrlCanonicalizeW(wszUrl, NULL, &dwSize, dwFlags) != dwExpectReturn, "Unexpected return for NULL buffer\n");
|
||||||
ok(UrlCanonicalizeW(wszUrl, wszReturnUrl, &dwSize, dwFlags) == dwExpectReturn, "UrlCanonicalizeW didn't return 0x%08lx\n", dwExpectReturn);
|
ok(UrlCanonicalizeW(wszUrl, wszReturnUrl, &dwSize, dwFlags) == dwExpectReturn, "UrlCanonicalizeW didn't return 0x%08lx\n", dwExpectReturn);
|
||||||
wszConvertedUrl = GetWideString(szReturnUrl);
|
wszConvertedUrl = GetWideString(szReturnUrl);
|
||||||
ok(strcmpW(wszReturnUrl, wszConvertedUrl)==0, "Strings didn't match between ascii and unicode UrlCanonicalize!\n");
|
ok(lstrcmpW(wszReturnUrl, wszConvertedUrl)==0, "Strings didn't match between ascii and unicode UrlCanonicalize!\n");
|
||||||
FreeWideString(wszConvertedUrl);
|
FreeWideString(wszConvertedUrl);
|
||||||
|
|
||||||
|
|
||||||
|
@ -489,7 +488,7 @@ static void test_url_combine(const char *szUrl1, const char *szUrl2, DWORD dwFla
|
||||||
ok(dwSize == dwExpectLen, "Got length %ld, expected %ld\n", dwSize, dwExpectLen);
|
ok(dwSize == dwExpectLen, "Got length %ld, expected %ld\n", dwSize, dwExpectLen);
|
||||||
if(SUCCEEDED(hr)) {
|
if(SUCCEEDED(hr)) {
|
||||||
wszConvertedUrl = GetWideString(szReturnUrl);
|
wszConvertedUrl = GetWideString(szReturnUrl);
|
||||||
ok(strcmpW(wszReturnUrl, wszConvertedUrl)==0, "Strings didn't match between ascii and unicode UrlCombine!\n");
|
ok(lstrcmpW(wszReturnUrl, wszConvertedUrl)==0, "Strings didn't match between ascii and unicode UrlCombine!\n");
|
||||||
FreeWideString(wszConvertedUrl);
|
FreeWideString(wszConvertedUrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -530,7 +529,7 @@ static void test_UrlCreateFromPath(void)
|
||||||
ok(ret == TEST_URLFROMPATH[i].ret, "ret %08lx from path L\"%s\", expected %08lx\n",
|
ok(ret == TEST_URLFROMPATH[i].ret, "ret %08lx from path L\"%s\", expected %08lx\n",
|
||||||
ret, TEST_URLFROMPATH[i].path, TEST_URLFROMPATH[i].ret);
|
ret, TEST_URLFROMPATH[i].path, TEST_URLFROMPATH[i].ret);
|
||||||
ok(!lstrcmpiW(ret_urlW, urlW), "got %s expected %s from path L\"%s\"\n", ret_url, TEST_URLFROMPATH[i].url, TEST_URLFROMPATH[i].path);
|
ok(!lstrcmpiW(ret_urlW, urlW), "got %s expected %s from path L\"%s\"\n", ret_url, TEST_URLFROMPATH[i].url, TEST_URLFROMPATH[i].path);
|
||||||
ok(len == strlenW(ret_urlW), "ret len %ld from path L\"%s\"\n", len, TEST_URLFROMPATH[i].path);
|
ok(len == lstrlenW(ret_urlW), "ret len %ld from path L\"%s\"\n", len, TEST_URLFROMPATH[i].path);
|
||||||
FreeWideString(urlW);
|
FreeWideString(urlW);
|
||||||
FreeWideString(pathW);
|
FreeWideString(pathW);
|
||||||
}
|
}
|
||||||
|
@ -599,7 +598,7 @@ static void test_UrlUnescape(void)
|
||||||
expected_urlW = GetWideString(TEST_URL_UNESCAPE[i].expect);
|
expected_urlW = GetWideString(TEST_URL_UNESCAPE[i].expect);
|
||||||
ok(UrlUnescapeW(urlW, ret_urlW, &dwEscaped, 0) == S_OK, "UrlEscapeW didn't return 0x%08lx from \"%s\"\n", S_OK, TEST_URL_UNESCAPE[i].url);
|
ok(UrlUnescapeW(urlW, ret_urlW, &dwEscaped, 0) == S_OK, "UrlEscapeW didn't return 0x%08lx from \"%s\"\n", S_OK, TEST_URL_UNESCAPE[i].url);
|
||||||
WideCharToMultiByte(CP_ACP,0,ret_urlW,-1,szReturnUrl,INTERNET_MAX_URL_LENGTH,0,0);
|
WideCharToMultiByte(CP_ACP,0,ret_urlW,-1,szReturnUrl,INTERNET_MAX_URL_LENGTH,0,0);
|
||||||
ok(strcmpW(ret_urlW, expected_urlW)==0, "Expected \"%s\", but got \"%s\" from \"%s\" flags %08lx\n", TEST_URL_UNESCAPE[i].expect, szReturnUrl, TEST_URL_UNESCAPE[i].url, 0L);
|
ok(lstrcmpW(ret_urlW, expected_urlW)==0, "Expected \"%s\", but got \"%s\" from \"%s\" flags %08lx\n", TEST_URL_UNESCAPE[i].expect, szReturnUrl, TEST_URL_UNESCAPE[i].url, 0L);
|
||||||
FreeWideString(urlW);
|
FreeWideString(urlW);
|
||||||
FreeWideString(expected_urlW);
|
FreeWideString(expected_urlW);
|
||||||
}
|
}
|
||||||
|
@ -634,7 +633,7 @@ static void test_PathSearchAndQualify(void)
|
||||||
"PathSearchAndQualify rets 0\n");
|
"PathSearchAndQualify rets 0\n");
|
||||||
GetFullPathNameW(c_drive, MAX_PATH, cur_dir, NULL);
|
GetFullPathNameW(c_drive, MAX_PATH, cur_dir, NULL);
|
||||||
PathAddBackslashW(cur_dir);
|
PathAddBackslashW(cur_dir);
|
||||||
strcatW(cur_dir, foo);
|
lstrcatW(cur_dir, foo);
|
||||||
ok(!lstrcmpiW(out, cur_dir), "strings don't match\n");
|
ok(!lstrcmpiW(out, cur_dir), "strings don't match\n");
|
||||||
|
|
||||||
/* foo */
|
/* foo */
|
||||||
|
@ -642,14 +641,14 @@ static void test_PathSearchAndQualify(void)
|
||||||
"PathSearchAndQualify rets 0\n");
|
"PathSearchAndQualify rets 0\n");
|
||||||
GetFullPathNameW(dot, MAX_PATH, cur_dir, NULL);
|
GetFullPathNameW(dot, MAX_PATH, cur_dir, NULL);
|
||||||
PathAddBackslashW(cur_dir);
|
PathAddBackslashW(cur_dir);
|
||||||
strcatW(cur_dir, foo);
|
lstrcatW(cur_dir, foo);
|
||||||
ok(!lstrcmpiW(out, cur_dir), "strings don't match\n");
|
ok(!lstrcmpiW(out, cur_dir), "strings don't match\n");
|
||||||
|
|
||||||
/* \foo */
|
/* \foo */
|
||||||
ok(PathSearchAndQualifyW(path3, out, MAX_PATH) != 0,
|
ok(PathSearchAndQualifyW(path3, out, MAX_PATH) != 0,
|
||||||
"PathSearchAndQualify rets 0\n");
|
"PathSearchAndQualify rets 0\n");
|
||||||
GetFullPathNameW(dot, MAX_PATH, cur_dir, NULL);
|
GetFullPathNameW(dot, MAX_PATH, cur_dir, NULL);
|
||||||
strcpyW(cur_dir + 2, path3);
|
lstrcpyW(cur_dir + 2, path3);
|
||||||
ok(!lstrcmpiW(out, cur_dir), "strings don't match\n");
|
ok(!lstrcmpiW(out, cur_dir), "strings don't match\n");
|
||||||
|
|
||||||
/* win.ini */
|
/* win.ini */
|
||||||
|
@ -685,7 +684,7 @@ static void test_PathCreateFromUrl(void)
|
||||||
ok(ret == TEST_PATHFROMURL[i].ret, "ret %08lx from url L\"%s\"\n", ret, TEST_PATHFROMURL[i].url);
|
ok(ret == TEST_PATHFROMURL[i].ret, "ret %08lx from url L\"%s\"\n", ret, TEST_PATHFROMURL[i].url);
|
||||||
if(TEST_PATHFROMURL[i].path) {
|
if(TEST_PATHFROMURL[i].path) {
|
||||||
ok(!lstrcmpiW(ret_pathW, pathW), "got %s expected %s from url L\"%s\"\n", ret_path, TEST_PATHFROMURL[i].path, TEST_PATHFROMURL[i].url);
|
ok(!lstrcmpiW(ret_pathW, pathW), "got %s expected %s from url L\"%s\"\n", ret_path, TEST_PATHFROMURL[i].path, TEST_PATHFROMURL[i].url);
|
||||||
ok(len == strlenW(ret_pathW), "ret len %ld from url L\"%s\"\n", len, TEST_PATHFROMURL[i].url);
|
ok(len == lstrlenW(ret_pathW), "ret len %ld from url L\"%s\"\n", len, TEST_PATHFROMURL[i].url);
|
||||||
}
|
}
|
||||||
FreeWideString(urlW);
|
FreeWideString(urlW);
|
||||||
FreeWideString(pathW);
|
FreeWideString(pathW);
|
||||||
|
|
Loading…
Reference in New Issue