Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
6de5669d
Commit
6de5669d
authored
Dec 15, 2009
by
Jacek Caban
Committed by
Alexandre Julliard
Dec 16, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
urlmon: Pass flags to test_BindToStorage.
parent
cd623036
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
29 deletions
+33
-29
url.c
dlls/urlmon/tests/url.c
+33
-29
No files found.
dlls/urlmon/tests/url.c
View file @
6de5669d
...
...
@@ -2184,9 +2184,10 @@ static BOOL test_RegisterBindStatusCallback(void)
return
ret
;
}
#define BINDTEST_EMULATE 1
#define BINDTEST_TOOBJECT 2
#define BINDTEST_FILEDWLAPI 4
#define BINDTEST_EMULATE 0x0001
#define BINDTEST_TOOBJECT 0x0002
#define BINDTEST_FILEDWLAPI 0x0004
#define BINDTEST_HTTPRESPONSE 0x0008
static
void
init_bind_test
(
int
protocol
,
DWORD
flags
,
DWORD
t
)
{
...
...
@@ -2201,9 +2202,13 @@ static void init_bind_test(int protocol, DWORD flags, DWORD t)
bind_to_object
=
(
flags
&
BINDTEST_TOOBJECT
)
!=
0
;
tymed
=
t
;
filedwl_api
=
(
flags
&
BINDTEST_FILEDWLAPI
)
!=
0
;
if
(
flags
&
BINDTEST_HTTPRESPONSE
)
urls
[
HTTP_TEST
]
=
SHORT_RESPONSE_URL
;
else
urls
[
HTTP_TEST
]
=
WINE_ABOUT_URL
;
}
static
void
test_BindToStorage
(
int
protocol
,
BOOL
emul
,
DWORD
t
)
static
void
test_BindToStorage
(
int
protocol
,
DWORD
flags
,
DWORD
t
)
{
IMoniker
*
mon
;
HRESULT
hres
;
...
...
@@ -2214,7 +2219,7 @@ static void test_BindToStorage(int protocol, BOOL emul, DWORD t)
IUnknown
*
unk
=
(
IUnknown
*
)
0x00ff00ff
;
IBinding
*
bind
;
init_bind_test
(
protocol
,
emul
?
BINDTEST_EMULATE
:
0
,
t
);
init_bind_test
(
protocol
,
flags
,
t
);
SET_EXPECT
(
QueryInterface_IServiceProvider
);
hres
=
CreateAsyncBindCtx
(
0
,
(
IBindStatusCallback
*
)
&
bsc
,
NULL
,
&
bctx
);
...
...
@@ -2571,7 +2576,7 @@ static void test_BindToObject(int protocol, BOOL emul)
CHECK_CALLED
(
Obj_OnStopBinding
);
}
if
(
test_protocol
!=
HTTP_TEST
||
emul
||
urls
[
test_protocol
]
==
SHORT_RESPONSE_URL
||
!
(
bindf
&
BINDF_ASYNCHRONOUS
))
{
if
(
test_protocol
!=
HTTP_TEST
||
emul
||
!
(
bindf
&
BINDF_ASYNCHRONOUS
))
{
ok
(
IMoniker_Release
(
mon
)
==
0
,
"mon should be destroyed here
\n
"
);
ok
(
IBindCtx_Release
(
bctx
)
==
0
,
"bctx should be destroyed here
\n
"
);
}
else
{
...
...
@@ -2842,7 +2847,7 @@ START_TEST(url)
test_BindToStorage_fail
();
trace
(
"synchronous http test (COM not initialised)...
\n
"
);
test_BindToStorage
(
HTTP_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTP_TEST
,
0
,
TYMED_ISTREAM
);
CoInitialize
(
NULL
);
...
...
@@ -2850,13 +2855,13 @@ START_TEST(url)
test_StdURLMoniker
();
trace
(
"synchronous http test...
\n
"
);
test_BindToStorage
(
HTTP_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTP_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"synchronous http test (to object)...
\n
"
);
test_BindToObject
(
HTTP_TEST
,
FALSE
);
trace
(
"synchronous file test...
\n
"
);
test_BindToStorage
(
FILE_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
FILE_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"synchronous file test (to object)...
\n
"
);
test_BindToObject
(
FILE_TEST
,
FALSE
);
...
...
@@ -2864,81 +2869,80 @@ START_TEST(url)
bindf
=
BINDF_ASYNCHRONOUS
|
BINDF_ASYNCSTORAGE
|
BINDF_PULLDATA
;
trace
(
"http test...
\n
"
);
test_BindToStorage
(
HTTP_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTP_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"http test (to file)...
\n
"
);
test_BindToStorage
(
HTTP_TEST
,
FALSE
,
TYMED_FILE
);
test_BindToStorage
(
HTTP_TEST
,
0
,
TYMED_FILE
);
trace
(
"http test (to object)...
\n
"
);
test_BindToObject
(
HTTP_TEST
,
FALSE
);
trace
(
"http test (short response)...
\n
"
);
http_is_first
=
TRUE
;
urls
[
HTTP_TEST
]
=
SHORT_RESPONSE_URL
;
test_BindToStorage
(
HTTP_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTP_TEST
,
BINDTEST_HTTPRESPONSE
,
TYMED_ISTREAM
);
trace
(
"http test (short response, to object)...
\n
"
);
test_BindToObject
(
HTTP_TEST
,
FALSE
);
trace
(
"emulated http test...
\n
"
);
test_BindToStorage
(
HTTP_TEST
,
TRU
E
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTP_TEST
,
BINDTEST_EMULAT
E
,
TYMED_ISTREAM
);
trace
(
"emulated http test (to object)...
\n
"
);
test_BindToObject
(
HTTP_TEST
,
TRUE
);
trace
(
"emulated http test (to file)...
\n
"
);
test_BindToStorage
(
HTTP_TEST
,
TRU
E
,
TYMED_FILE
);
test_BindToStorage
(
HTTP_TEST
,
BINDTEST_EMULAT
E
,
TYMED_FILE
);
trace
(
"asynchronous https test...
\n
"
);
test_BindToStorage
(
HTTPS_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTPS_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"emulated https test...
\n
"
);
test_BindToStorage
(
HTTPS_TEST
,
TRU
E
,
TYMED_ISTREAM
);
test_BindToStorage
(
HTTPS_TEST
,
BINDTEST_EMULAT
E
,
TYMED_ISTREAM
);
trace
(
"about test...
\n
"
);
test_BindToStorage
(
ABOUT_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
ABOUT_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"about test (to file)...
\n
"
);
test_BindToStorage
(
ABOUT_TEST
,
FALS
E
,
TYMED_FILE
);
test_BindToStorage
(
ABOUT_TEST
,
BINDTEST_EMULAT
E
,
TYMED_FILE
);
trace
(
"about test (to object)...
\n
"
);
test_BindToObject
(
ABOUT_TEST
,
FALSE
);
trace
(
"emulated about test...
\n
"
);
test_BindToStorage
(
ABOUT_TEST
,
TRU
E
,
TYMED_ISTREAM
);
test_BindToStorage
(
ABOUT_TEST
,
BINDTEST_EMULAT
E
,
TYMED_ISTREAM
);
trace
(
"emulated about test (to file)...
\n
"
);
test_BindToStorage
(
ABOUT_TEST
,
TRU
E
,
TYMED_FILE
);
test_BindToStorage
(
ABOUT_TEST
,
BINDTEST_EMULAT
E
,
TYMED_FILE
);
trace
(
"emulated about test (to object)...
\n
"
);
test_BindToObject
(
ABOUT_TEST
,
TRUE
);
trace
(
"file test...
\n
"
);
test_BindToStorage
(
FILE_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
FILE_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"file test (to file)...
\n
"
);
test_BindToStorage
(
FILE_TEST
,
FALSE
,
TYMED_FILE
);
test_BindToStorage
(
FILE_TEST
,
0
,
TYMED_FILE
);
trace
(
"file test (to object)...
\n
"
);
test_BindToObject
(
FILE_TEST
,
FALSE
);
trace
(
"emulated file test...
\n
"
);
test_BindToStorage
(
FILE_TEST
,
TRU
E
,
TYMED_ISTREAM
);
test_BindToStorage
(
FILE_TEST
,
BINDTEST_EMULAT
E
,
TYMED_ISTREAM
);
trace
(
"emulated file test (to file)...
\n
"
);
test_BindToStorage
(
FILE_TEST
,
TRU
E
,
TYMED_FILE
);
test_BindToStorage
(
FILE_TEST
,
BINDTEST_EMULAT
E
,
TYMED_FILE
);
trace
(
"emulated file test (to object)...
\n
"
);
test_BindToObject
(
FILE_TEST
,
TRUE
);
trace
(
"emulated its test...
\n
"
);
test_BindToStorage
(
ITS_TEST
,
TRU
E
,
TYMED_ISTREAM
);
test_BindToStorage
(
ITS_TEST
,
BINDTEST_EMULAT
E
,
TYMED_ISTREAM
);
trace
(
"emulated its test (to file)...
\n
"
);
test_BindToStorage
(
ITS_TEST
,
TRU
E
,
TYMED_FILE
);
test_BindToStorage
(
ITS_TEST
,
BINDTEST_EMULAT
E
,
TYMED_FILE
);
trace
(
"emulated mk test...
\n
"
);
test_BindToStorage
(
MK_TEST
,
TRU
E
,
TYMED_ISTREAM
);
test_BindToStorage
(
MK_TEST
,
BINDTEST_EMULAT
E
,
TYMED_ISTREAM
);
trace
(
"test URLDownloadToFile for file protocol...
\n
"
);
test_URLDownloadToFile
(
FILE_TEST
,
FALSE
);
...
...
@@ -2952,7 +2956,7 @@ START_TEST(url)
bindf
|=
BINDF_NOWRITECACHE
;
trace
(
"ftp test...
\n
"
);
test_BindToStorage
(
FTP_TEST
,
FALSE
,
TYMED_ISTREAM
);
test_BindToStorage
(
FTP_TEST
,
0
,
TYMED_ISTREAM
);
trace
(
"test failures...
\n
"
);
test_BindToStorage_fail
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment