Commit 63b53ff5 authored by Detlef Riekenberg's avatar Detlef Riekenberg Committed by Alexandre Julliard

urlmon/tests: Skip protocol tests on IE 4.0.

Register the filters is not possible due to the missing functions. No tests left, so skip all of them (winetestbot W95B).
parent 7458345f
......@@ -29,6 +29,9 @@
#include "urlmon.h"
#include "wininet.h"
static HRESULT (WINAPI *pCoInternetGetSession)(DWORD, IInternetSession **, DWORD);
static HRESULT (WINAPI *pReleaseBindInfo)(BINDINFO*);
#define DEFINE_EXPECT(func) \
static BOOL expect_ ## func = FALSE, called_ ## func = FALSE
......@@ -1318,7 +1321,7 @@ static HRESULT WINAPI ProtocolEmul_Start(IInternetProtocol *iface, LPCWSTR szUrl
ok(cbindf == (bindf|BINDF_FROMURLMON), "bindf = %x, expected %x\n",
cbindf, (bindf|BINDF_FROMURLMON));
ok(!memcmp(&exp_bindinfo, &bindinfo, sizeof(bindinfo)), "unexpected bindinfo\n");
ReleaseBindInfo(&bindinfo);
pReleaseBindInfo(&bindinfo);
SET_EXPECT(ReportProgress_SENDINGREQUEST);
hres = IInternetProtocolSink_ReportProgress(pOIProtSink, BINDSTATUS_SENDINGREQUEST, emptyW);
......@@ -2793,7 +2796,7 @@ static void test_CreateBinding(void)
trace("Testing CreateBinding...\n");
init_test(BIND_TEST, TEST_BINDING);
hres = CoInternetGetSession(0, &session, 0);
hres = pCoInternetGetSession(0, &session, 0);
ok(hres == S_OK, "CoInternetGetSession failed: %08x\n", hres);
hres = IInternetSession_RegisterNameSpace(session, &ClassFactory, &IID_NULL, wsz_test, 0, NULL, 0);
......@@ -2932,7 +2935,7 @@ static void test_binding(int prot, DWORD grf_pi, DWORD test_flags)
init_test(prot, test_flags|TEST_BINDING);
hres = CoInternetGetSession(0, &session, 0);
hres = pCoInternetGetSession(0, &session, 0);
ok(hres == S_OK, "CoInternetGetSession failed: %08x\n", hres);
if(test_flags & TEST_EMULATEPROT) {
......@@ -3042,7 +3045,8 @@ static void register_filter(void)
static const WCHAR gzipW[] = {'g','z','i','p',0};
CoInternetGetSession(0, &session, 0);
hres = pCoInternetGetSession(0, &session, 0);
ok(hres == S_OK, "CoInternetGetSession failed: %08x\n", hres);
hres = IInternetSession_RegisterMimeFilter(session, &mimefilter_cf, &IID_IInternetProtocol, gzipW);
ok(hres == S_OK, "RegisterMimeFilter failed: %08x\n", hres);
......@@ -3052,6 +3056,17 @@ static void register_filter(void)
START_TEST(protocol)
{
HMODULE hurlmon;
hurlmon = GetModuleHandle("urlmon.dll");
pCoInternetGetSession = (void*) GetProcAddress(hurlmon, "CoInternetGetSession");
pReleaseBindInfo = (void*) GetProcAddress(hurlmon, "ReleaseBindInfo");
if (!pCoInternetGetSession || !pReleaseBindInfo) {
win_skip("Various needed functions not present in IE 4.0\n");
return;
}
OleInitialize(NULL);
event_complete = CreateEvent(NULL, FALSE, FALSE, NULL);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment