Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
955fe0da
Commit
955fe0da
authored
Jul 03, 2006
by
Detlef Riekenberg
Committed by
Alexandre Julliard
Jul 06, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
comdlg32: Add initial test.
parent
67fcd2f1
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
106 additions
and
0 deletions
+106
-0
configure
configure
+0
-0
configure.ac
configure.ac
+1
-0
Makefile.in
dlls/comdlg32/Makefile.in
+2
-0
.gitignore
dlls/comdlg32/tests/.gitignore
+3
-0
Makefile.in
dlls/comdlg32/tests/Makefile.in
+13
-0
printdlg.c
dlls/comdlg32/tests/printdlg.c
+84
-0
Makefile.in
programs/winetest/Makefile.in
+3
-0
No files found.
configure
View file @
955fe0da
This diff is collapsed.
Click to expand it.
configure.ac
View file @
955fe0da
...
...
@@ -1568,6 +1568,7 @@ dlls/comcat/Makefile
dlls/comctl32/Makefile
dlls/comctl32/tests/Makefile
dlls/comdlg32/Makefile
dlls/comdlg32/tests/Makefile
dlls/compstui/Makefile
dlls/crtdll/Makefile
dlls/crypt32/Makefile
...
...
dlls/comdlg32/Makefile.in
View file @
955fe0da
...
...
@@ -44,6 +44,8 @@ RC_BINARIES = \
pd32_nocollate.ico
\
pd32_portrait.ico
SUBDIRS
=
tests
@MAKE_DLL_RULES@
### Dependencies:
dlls/comdlg32/tests/.gitignore
0 → 100644
View file @
955fe0da
Makefile
printdlg.ok
testlist.c
dlls/comdlg32/tests/Makefile.in
0 → 100644
View file @
955fe0da
TOPSRCDIR
=
@top_srcdir@
TOPOBJDIR
=
../../..
SRCDIR
=
@srcdir@
VPATH
=
@srcdir@
TESTDLL
=
comdlg32.dll
IMPORTS
=
comdlg32 kernel32
CTESTS
=
\
printdlg.c
@MAKE_TEST_RULES@
### Dependencies:
dlls/comdlg32/tests/printdlg.c
0 → 100644
View file @
955fe0da
/*
* Unit test suite for comdlg32 API functions: printer dialogs
*
* Copyright 2006 Detlef Riekenberg
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*
*/
#include <stdarg.h>
#include "windef.h"
#include "winbase.h"
#include "winerror.h"
#include "wingdi.h"
#include "wingdi.h"
#include "winuser.h"
#include "cderr.h"
#include "commdlg.h"
#include "wine/test.h"
/* ##### */
static
void
test_PrintDlgA
(
void
)
{
DWORD
res
;
LPPRINTDLGA
pDlg
;
pDlg
=
HeapAlloc
(
GetProcessHeap
(),
0
,
(
sizeof
(
PRINTDLGA
))
*
2
);
if
(
!
pDlg
)
return
;
#if 0
/* will crash with unpatched wine */
SetLastError(0xdeadbeef);
res = PrintDlgA(NULL);
ok( !res && (CommDlgExtendedError() == CDERR_INITIALIZATION),
"returned %ld with 0x%lx and 0x%lx (expected '0' and " \
"CDERR_INITIALIZATION)\n", res, GetLastError(), CommDlgExtendedError());
}
#endif
ZeroMemory
(
pDlg
,
sizeof
(
PRINTDLGA
));
pDlg
->
lStructSize
=
sizeof
(
PRINTDLGA
)
-
1
;
SetLastError
(
0xdeadbeef
);
res
=
PrintDlgA
(
pDlg
);
ok
(
!
res
&&
(
CommDlgExtendedError
()
==
CDERR_STRUCTSIZE
),
"returned %ld with 0x%lx and 0x%lx (expected '0' and "
\
"CDERR_STRUCTSIZE)
\n
"
,
res
,
GetLastError
(),
CommDlgExtendedError
());
ZeroMemory
(
pDlg
,
sizeof
(
PRINTDLGA
));
pDlg
->
lStructSize
=
sizeof
(
PRINTDLGA
);
pDlg
->
Flags
=
PD_RETURNDEFAULT
;
SetLastError
(
0xdeadbeef
);
res
=
PrintDlgA
(
pDlg
);
ok
(
res
,
"returned %ld with 0x%lx and 0x%lx (expected '!= 0')
\n
"
,
res
,
GetLastError
(),
CommDlgExtendedError
());
HeapFree
(
GetProcessHeap
(),
0
,
pDlg
);
}
START_TEST
(
printdlg
)
{
test_PrintDlgA
();
}
programs/winetest/Makefile.in
View file @
955fe0da
...
...
@@ -23,6 +23,7 @@ TESTBINS = \
advpack_test.exe
$(DLLEXT)
\
cabinet_test.exe
$(DLLEXT)
\
comctl32_test.exe
$(DLLEXT)
\
comdlg32_test.exe
$(DLLEXT)
\
crypt32_test.exe
$(DLLEXT)
\
d3d8_test.exe
$(DLLEXT)
\
d3d9_test.exe
$(DLLEXT)
\
...
...
@@ -109,6 +110,8 @@ cabinet_test.exe$(DLLEXT): $(DLLDIR)/cabinet/tests/cabinet_test.exe$(DLLEXT)
cp
$(DLLDIR)
/cabinet/tests/cabinet_test.exe
$(DLLEXT)
$@
&&
$(STRIP)
$@
comctl32_test.exe$(DLLEXT)
:
$(DLLDIR)/comctl32/tests/comctl32_test.exe$(DLLEXT)
cp
$(DLLDIR)
/comctl32/tests/comctl32_test.exe
$(DLLEXT)
$@
&&
$(STRIP)
$@
comdlg32_test.exe$(DLLEXT)
:
$(DLLDIR)/comdlg32/tests/comdlg32_test.exe$(DLLEXT)
cp
$(DLLDIR)
/comdlg32/tests/comdlg32_test.exe
$(DLLEXT)
$@
&&
$(STRIP)
$@
crypt32_test.exe$(DLLEXT)
:
$(DLLDIR)/crypt32/tests/crypt32_test.exe$(DLLEXT)
cp
$(DLLDIR)
/crypt32/tests/crypt32_test.exe
$(DLLEXT)
$@
&&
$(STRIP)
$@
d3d8_test.exe$(DLLEXT)
:
$(DLLDIR)/d3d8/tests/d3d8_test.exe$(DLLEXT)
...
...
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