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
69cf6a28
Commit
69cf6a28
authored
Aug 17, 2005
by
Saulius Krasuckas
Committed by
Alexandre Julliard
Aug 17, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Correct failing test and transform it into a bunch of another tests.
parent
03ede200
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
49 additions
and
1 deletion
+49
-1
http.c
dlls/wininet/tests/http.c
+49
-1
No files found.
dlls/wininet/tests/http.c
View file @
69cf6a28
...
...
@@ -330,6 +330,7 @@ static void InternetCrackUrl_test(void)
char
protocol
[
32
],
hostName
[
1024
],
userName
[
1024
];
char
password
[
1024
],
extra
[
1024
],
path
[
1024
];
BOOL
ret
;
DWORD
GLE
;
ZeroMemory
(
&
urlSrc
,
sizeof
(
urlSrc
));
urlSrc
.
dwStructSize
=
sizeof
(
urlSrc
);
...
...
@@ -365,8 +366,55 @@ static void InternetCrackUrl_test(void)
ok
(
!
strncmp
(
urlComponents
.
lpszHostName
,
TEST_URL2_SERVER
,
strlen
(
TEST_URL2_SERVER
)),
"lpszHostName should be %s but is %s
\n
"
,
TEST_URL2_SERVER
,
urlComponents
.
lpszHostName
);
/*3. Check for %20 */
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
1024
,
1024
,
1024
,
2048
,
0
);
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
1024
,
1024
,
1024
,
2048
,
1024
);
ok
(
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
),
"InternetCrackUrl failed with GLE 0x%lx
\n
"
,
GetLastError
());
/* Tests for lpsz* members pointing to real strings while
* some corresponding length members are set to zero */
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
0
,
1024
,
1024
,
1024
,
2048
,
1024
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
ok
(
ret
==
1
,
"InternetCrackUrl returned %d with GLE=%ld (expected to return 1)
\n
"
,
ret
,
GetLastError
());
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
0
,
1024
,
1024
,
2048
,
1024
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
ok
(
ret
==
1
,
"InternetCrackUrl returned %d with GLE=%ld (expected to return 1)
\n
"
,
ret
,
GetLastError
());
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
1024
,
0
,
1024
,
2048
,
1024
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
ok
(
ret
==
1
,
"InternetCrackUrl returned %d with GLE=%ld (expected to return 1)
\n
"
,
ret
,
GetLastError
());
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
1024
,
1024
,
0
,
2048
,
1024
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
ok
(
ret
==
1
,
"InternetCrackUrl returned %d with GLE=%ld (expected to return 1)
\n
"
,
ret
,
GetLastError
());
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
1024
,
1024
,
1024
,
0
,
1024
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
GLE
=
GetLastError
();
todo_wine
ok
(
ret
==
0
&&
(
GLE
==
ERROR_INVALID_HANDLE
||
GLE
==
ERROR_INSUFFICIENT_BUFFER
),
"InternetCrackUrl returned %d with GLE=%ld (expected to return 0 and ERROR_INVALID_HANDLE or ERROR_INSUFFICIENT_BUFFER)
\n
"
,
ret
,
GLE
);
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
32
,
1024
,
1024
,
1024
,
2048
,
0
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
GLE
=
GetLastError
();
todo_wine
ok
(
ret
==
0
&&
(
GLE
==
ERROR_INVALID_HANDLE
||
GLE
==
ERROR_INSUFFICIENT_BUFFER
),
"InternetCrackUrl returned %d with GLE=%ld (expected to return 0 and ERROR_INVALID_HANDLE or ERROR_INSUFFICIENT_BUFFER)
\n
"
,
ret
,
GLE
);
copy_compsA
(
&
urlSrc
,
&
urlComponents
,
0
,
0
,
0
,
0
,
0
,
0
);
ret
=
InternetCrackUrlA
(
TEST_URL3
,
0
,
ICU_DECODE
,
&
urlComponents
);
GLE
=
GetLastError
();
todo_wine
ok
(
ret
==
0
&&
GLE
==
ERROR_INVALID_PARAMETER
,
"InternetCrackUrl returned %d with GLE=%ld (expected to return 0 and ERROR_INVALID_PARAMETER)
\n
"
,
ret
,
GLE
);
}
static
void
InternetCrackUrlW_test
(
void
)
...
...
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