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
d2d8d71e
Commit
d2d8d71e
authored
May 28, 2008
by
Paul Vriens
Committed by
Alexandre Julliard
May 28, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
user32/tests: Run tests on win95 again.
parent
89164d42
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
7 deletions
+15
-7
win.c
dlls/user32/tests/win.c
+15
-7
No files found.
dlls/user32/tests/win.c
View file @
d2d8d71e
...
@@ -46,6 +46,7 @@ void dump_region(HRGN hrgn);
...
@@ -46,6 +46,7 @@ void dump_region(HRGN hrgn);
static
HWND
(
WINAPI
*
pGetAncestor
)(
HWND
,
UINT
);
static
HWND
(
WINAPI
*
pGetAncestor
)(
HWND
,
UINT
);
static
BOOL
(
WINAPI
*
pGetWindowInfo
)(
HWND
,
WINDOWINFO
*
);
static
BOOL
(
WINAPI
*
pGetWindowInfo
)(
HWND
,
WINDOWINFO
*
);
static
UINT
(
WINAPI
*
pGetWindowModuleFileNameA
)(
HWND
,
LPSTR
,
UINT
);
static
BOOL
test_lbuttondown_flag
;
static
BOOL
test_lbuttondown_flag
;
static
HWND
hwndMessage
;
static
HWND
hwndMessage
;
...
@@ -4638,6 +4639,12 @@ static void test_GetWindowModuleFileName(void)
...
@@ -4638,6 +4639,12 @@ static void test_GetWindowModuleFileName(void)
UINT
ret1
,
ret2
;
UINT
ret1
,
ret2
;
char
buf1
[
MAX_PATH
],
buf2
[
MAX_PATH
];
char
buf1
[
MAX_PATH
],
buf2
[
MAX_PATH
];
if
(
!
pGetWindowModuleFileNameA
)
{
skip
(
"GetWindowModuleFileNameA is not available
\n
"
);
return
;
}
hwnd
=
CreateWindowExA
(
0
,
"static"
,
NULL
,
WS_POPUP
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
NULL
);
hwnd
=
CreateWindowExA
(
0
,
"static"
,
NULL
,
WS_POPUP
,
0
,
0
,
0
,
0
,
0
,
0
,
0
,
NULL
);
assert
(
hwnd
);
assert
(
hwnd
);
...
@@ -4651,8 +4658,8 @@ static void test_GetWindowModuleFileName(void)
...
@@ -4651,8 +4658,8 @@ static void test_GetWindowModuleFileName(void)
buf2
[
0
]
=
0
;
buf2
[
0
]
=
0
;
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
ret2
=
GetWindowModuleFileName
(
hwnd
,
buf2
,
sizeof
(
buf2
));
ret2
=
pGetWindowModuleFileNameA
(
hwnd
,
buf2
,
sizeof
(
buf2
));
ok
(
ret2
,
"GetWindowModuleFileName error %u
\n
"
,
GetLastError
());
ok
(
ret2
,
"GetWindowModuleFileName
A
error %u
\n
"
,
GetLastError
());
ok
(
ret1
==
ret2
,
"%u != %u
\n
"
,
ret1
,
ret2
);
ok
(
ret1
==
ret2
,
"%u != %u
\n
"
,
ret1
,
ret2
);
ok
(
!
strcmp
(
buf1
,
buf2
),
"%s != %s
\n
"
,
buf1
,
buf2
);
ok
(
!
strcmp
(
buf1
,
buf2
),
"%s != %s
\n
"
,
buf1
,
buf2
);
...
@@ -4671,12 +4678,12 @@ static void test_GetWindowModuleFileName(void)
...
@@ -4671,12 +4678,12 @@ static void test_GetWindowModuleFileName(void)
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
ret2
=
GetWindowModuleFileName
(
hwnd
,
buf2
,
ret1
-
2
);
ret2
=
pGetWindowModuleFileNameA
(
hwnd
,
buf2
,
ret1
-
2
);
ok
(
ret2
==
ret1
-
2
,
"expected %u, got %u
\n
"
,
ret1
-
2
,
ret2
);
ok
(
ret2
==
ret1
-
2
,
"expected %u, got %u
\n
"
,
ret1
-
2
,
ret2
);
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
ret2
=
GetWindowModuleFileName
(
hwnd
,
buf2
,
0
);
ret2
=
pGetWindowModuleFileNameA
(
hwnd
,
buf2
,
0
);
ok
(
!
ret2
,
"expected 0, got %u
\n
"
,
ret2
);
ok
(
!
ret2
,
"expected 0, got %u
\n
"
,
ret2
);
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
ok
(
GetLastError
()
==
0xdeadbeef
,
"expected 0xdeadbeef, got %u
\n
"
,
GetLastError
());
...
@@ -4685,20 +4692,20 @@ static void test_GetWindowModuleFileName(void)
...
@@ -4685,20 +4692,20 @@ static void test_GetWindowModuleFileName(void)
buf2
[
0
]
=
0
;
buf2
[
0
]
=
0
;
hwnd
=
(
HWND
)
0xdeadbeef
;
hwnd
=
(
HWND
)
0xdeadbeef
;
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
ret1
=
GetWindowModuleFileName
(
hwnd
,
buf1
,
sizeof
(
buf1
));
ret1
=
pGetWindowModuleFileNameA
(
hwnd
,
buf1
,
sizeof
(
buf1
));
ok
(
!
ret1
,
"expected 0, got %u
\n
"
,
ret1
);
ok
(
!
ret1
,
"expected 0, got %u
\n
"
,
ret1
);
ok
(
GetLastError
()
==
ERROR_INVALID_WINDOW_HANDLE
,
"expected ERROR_INVALID_WINDOW_HANDLE, got %u
\n
"
,
GetLastError
());
ok
(
GetLastError
()
==
ERROR_INVALID_WINDOW_HANDLE
,
"expected ERROR_INVALID_WINDOW_HANDLE, got %u
\n
"
,
GetLastError
());
hwnd
=
GetDesktopWindow
();
hwnd
=
GetDesktopWindow
();
ok
(
IsWindow
(
hwnd
),
"got invalid desktop window %p
\n
"
,
hwnd
);
ok
(
IsWindow
(
hwnd
),
"got invalid desktop window %p
\n
"
,
hwnd
);
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
ret1
=
GetWindowModuleFileName
(
hwnd
,
buf1
,
sizeof
(
buf1
));
ret1
=
pGetWindowModuleFileNameA
(
hwnd
,
buf1
,
sizeof
(
buf1
));
ok
(
!
ret1
,
"expected 0, got %u
\n
"
,
ret1
);
ok
(
!
ret1
,
"expected 0, got %u
\n
"
,
ret1
);
hwnd
=
FindWindow
(
"Shell_TrayWnd"
,
NULL
);
hwnd
=
FindWindow
(
"Shell_TrayWnd"
,
NULL
);
ok
(
IsWindow
(
hwnd
),
"got invalid tray window %p
\n
"
,
hwnd
);
ok
(
IsWindow
(
hwnd
),
"got invalid tray window %p
\n
"
,
hwnd
);
SetLastError
(
0xdeadbeef
);
SetLastError
(
0xdeadbeef
);
ret1
=
GetWindowModuleFileName
(
hwnd
,
buf1
,
sizeof
(
buf1
));
ret1
=
pGetWindowModuleFileNameA
(
hwnd
,
buf1
,
sizeof
(
buf1
));
ok
(
!
ret1
,
"expected 0, got %u
\n
"
,
ret1
);
ok
(
!
ret1
,
"expected 0, got %u
\n
"
,
ret1
);
}
}
...
@@ -4706,6 +4713,7 @@ START_TEST(win)
...
@@ -4706,6 +4713,7 @@ START_TEST(win)
{
{
pGetAncestor
=
(
void
*
)
GetProcAddress
(
GetModuleHandleA
(
"user32.dll"
),
"GetAncestor"
);
pGetAncestor
=
(
void
*
)
GetProcAddress
(
GetModuleHandleA
(
"user32.dll"
),
"GetAncestor"
);
pGetWindowInfo
=
(
void
*
)
GetProcAddress
(
GetModuleHandleA
(
"user32.dll"
),
"GetWindowInfo"
);
pGetWindowInfo
=
(
void
*
)
GetProcAddress
(
GetModuleHandleA
(
"user32.dll"
),
"GetWindowInfo"
);
pGetWindowModuleFileNameA
=
(
void
*
)
GetProcAddress
(
GetModuleHandleA
(
"user32.dll"
),
"GetWindowModuleFileNameA"
);
hwndMain
=
CreateWindowExA
(
0
,
"static"
,
NULL
,
0
,
0
,
0
,
0
,
0
,
HWND_MESSAGE
,
0
,
0
,
NULL
);
hwndMain
=
CreateWindowExA
(
0
,
"static"
,
NULL
,
0
,
0
,
0
,
0
,
0
,
HWND_MESSAGE
,
0
,
0
,
NULL
);
if
(
hwndMain
)
if
(
hwndMain
)
...
...
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