mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 09:13:01 +00:00
Forgot to commit urlmon.dll tests synced with Wine HEAD
svn path=/trunk/; revision=33564
This commit is contained in:
parent
0cbcee9d20
commit
8fdd4d9b2a
2 changed files with 21 additions and 8 deletions
|
@ -27,6 +27,7 @@
|
||||||
#include "winbase.h"
|
#include "winbase.h"
|
||||||
#include "ole2.h"
|
#include "ole2.h"
|
||||||
#include "urlmon.h"
|
#include "urlmon.h"
|
||||||
|
#include "wininet.h"
|
||||||
|
|
||||||
#include "initguid.h"
|
#include "initguid.h"
|
||||||
|
|
||||||
|
@ -1383,11 +1384,21 @@ static void test_file_protocol_fail(void)
|
||||||
CHECK_CALLED(ReportProgress_SENDINGREQUEST);
|
CHECK_CALLED(ReportProgress_SENDINGREQUEST);
|
||||||
CHECK_CALLED(ReportResult);
|
CHECK_CALLED(ReportResult);
|
||||||
|
|
||||||
|
SET_EXPECT(GetBindInfo);
|
||||||
|
hres = IInternetProtocol_Start(protocol, NULL, &protocol_sink, &bind_info, 0, 0);
|
||||||
|
ok(hres == E_INVALIDARG, "Start failed: %08x, expected E_INVALIDARG\n", hres);
|
||||||
|
CHECK_CALLED(GetBindInfo);
|
||||||
|
|
||||||
|
SET_EXPECT(GetBindInfo);
|
||||||
|
hres = IInternetProtocol_Start(protocol, emptyW, &protocol_sink, &bind_info, 0, 0);
|
||||||
|
ok(hres == E_INVALIDARG, "Start failed: %08x, expected E_INVALIDARG\n", hres);
|
||||||
|
CHECK_CALLED(GetBindInfo);
|
||||||
|
|
||||||
IInternetProtocol_Release(protocol);
|
IInternetProtocol_Release(protocol);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void test_file_protocol(void) {
|
static void test_file_protocol(void) {
|
||||||
WCHAR buf[MAX_PATH];
|
WCHAR buf[INTERNET_MAX_URL_LENGTH], file_name_buf[MAX_PATH];
|
||||||
DWORD size;
|
DWORD size;
|
||||||
ULONG len;
|
ULONG len;
|
||||||
HANDLE file;
|
HANDLE file;
|
||||||
|
@ -1429,17 +1440,19 @@ static void test_file_protocol(void) {
|
||||||
test_file_protocol_url(buf);
|
test_file_protocol_url(buf);
|
||||||
|
|
||||||
memcpy(buf, wszFile2, sizeof(wszFile2));
|
memcpy(buf, wszFile2, sizeof(wszFile2));
|
||||||
len = sizeof(wszFile2)/sizeof(WCHAR)-1;
|
len = GetCurrentDirectoryW(sizeof(file_name_buf)/sizeof(WCHAR), file_name_buf);
|
||||||
len += GetCurrentDirectoryW(sizeof(buf)/sizeof(WCHAR)-len, buf+len);
|
file_name_buf[len++] = '\\';
|
||||||
buf[len++] = '\\';
|
memcpy(file_name_buf+len, wszIndexHtml, sizeof(wszIndexHtml));
|
||||||
memcpy(buf+len, wszIndexHtml, sizeof(wszIndexHtml));
|
lstrcpyW(buf+sizeof(wszFile2)/sizeof(WCHAR)-1, file_name_buf);
|
||||||
|
file_name = file_name_buf;
|
||||||
file_name = buf + sizeof(wszFile2)/sizeof(WCHAR)-1;
|
|
||||||
bindf = 0;
|
bindf = 0;
|
||||||
test_file_protocol_url(buf);
|
test_file_protocol_url(buf);
|
||||||
bindf = BINDF_FROMURLMON;
|
bindf = BINDF_FROMURLMON;
|
||||||
test_file_protocol_url(buf);
|
test_file_protocol_url(buf);
|
||||||
|
|
||||||
|
buf[sizeof(wszFile2)/sizeof(WCHAR)] = '|';
|
||||||
|
test_file_protocol_url(buf);
|
||||||
|
|
||||||
memcpy(buf, wszFile3, sizeof(wszFile3));
|
memcpy(buf, wszFile3, sizeof(wszFile3));
|
||||||
len = sizeof(wszFile3)/sizeof(WCHAR)-1;
|
len = sizeof(wszFile3)/sizeof(WCHAR)-1;
|
||||||
len += GetCurrentDirectoryW(sizeof(buf)/sizeof(WCHAR)-len, buf+len);
|
len += GetCurrentDirectoryW(sizeof(buf)/sizeof(WCHAR)-len, buf+len);
|
||||||
|
|
|
@ -12,12 +12,12 @@
|
||||||
<file>url.c</file>
|
<file>url.c</file>
|
||||||
<file>testlist.c</file>
|
<file>testlist.c</file>
|
||||||
<library>wine</library>
|
<library>wine</library>
|
||||||
|
<library>uuid</library>
|
||||||
<library>urlmon</library>
|
<library>urlmon</library>
|
||||||
<library>ole32</library>
|
<library>ole32</library>
|
||||||
<library>user32</library>
|
<library>user32</library>
|
||||||
<library>advapi32</library>
|
<library>advapi32</library>
|
||||||
<library>kernel32</library>
|
<library>kernel32</library>
|
||||||
<library>uuid</library>
|
|
||||||
<library>ntdll</library>
|
<library>ntdll</library>
|
||||||
</module>
|
</module>
|
||||||
</group>
|
</group>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue