urlmon: Fixed tests on IE7.

This commit is contained in:
Jacek Caban 2007-10-25 22:26:32 +02:00 committed by Alexandre Julliard
parent f4f0c8fbcd
commit c98ca177a8
2 changed files with 6 additions and 5 deletions

View File

@ -122,6 +122,9 @@ static HRESULT WINAPI MkProtocol_Start(IInternetProtocol *iface, LPCWSTR szUrl,
TRACE("(%p)->(%s %p %p %08x %d)\n", This, debugstr_w(szUrl), pOIProtSink, TRACE("(%p)->(%s %p %p %08x %d)\n", This, debugstr_w(szUrl), pOIProtSink,
pOIBindInfo, grfPI, dwReserved); pOIBindInfo, grfPI, dwReserved);
if(strncmpiW(szUrl, wszMK, sizeof(wszMK)/sizeof(WCHAR)))
return INET_E_INVALID_URL;
memset(&bindinfo, 0, sizeof(bindinfo)); memset(&bindinfo, 0, sizeof(bindinfo));
bindinfo.cbSize = sizeof(BINDINFO); bindinfo.cbSize = sizeof(BINDINFO);
hres = IInternetBindInfo_GetBindInfo(pOIBindInfo, &bindf, &bindinfo); hres = IInternetBindInfo_GetBindInfo(pOIBindInfo, &bindf, &bindinfo);
@ -132,9 +135,6 @@ static HRESULT WINAPI MkProtocol_Start(IInternetProtocol *iface, LPCWSTR szUrl,
ReleaseBindInfo(&bindinfo); ReleaseBindInfo(&bindinfo);
if(strncmpiW(szUrl, wszMK, sizeof(wszMK)/sizeof(WCHAR)))
return MK_E_SYNTAX;
IInternetProtocolSink_ReportProgress(pOIProtSink, BINDSTATUS_DIRECTBIND, NULL); IInternetProtocolSink_ReportProgress(pOIProtSink, BINDSTATUS_DIRECTBIND, NULL);
IInternetProtocolSink_ReportProgress(pOIProtSink, BINDSTATUS_SENDINGREQUEST, NULL); IInternetProtocolSink_ReportProgress(pOIProtSink, BINDSTATUS_SENDINGREQUEST, NULL);

View File

@ -1404,8 +1404,9 @@ static void test_mk_protocol(void)
SET_EXPECT(GetBindInfo); SET_EXPECT(GetBindInfo);
hres = IInternetProtocol_Start(protocol, wrong_url1, &protocol_sink, &bind_info, 0, 0); hres = IInternetProtocol_Start(protocol, wrong_url1, &protocol_sink, &bind_info, 0, 0);
ok(hres == MK_E_SYNTAX, "Start failed: %08x, expected MK_E_SYNTAX\n", hres); ok(hres == MK_E_SYNTAX || hres == INET_E_INVALID_URL,
CHECK_CALLED(GetBindInfo); "Start failed: %08x, expected MK_E_SYNTAX or INET_E_INVALID_URL\n", hres);
CLEAR_CALLED(GetBindInfo);
SET_EXPECT(GetBindInfo); SET_EXPECT(GetBindInfo);
SET_EXPECT(ReportProgress_DIRECTBIND); SET_EXPECT(ReportProgress_DIRECTBIND);