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
a85adf31
Commit
a85adf31
authored
Feb 09, 2011
by
Austin English
Committed by
Alexandre Julliard
Feb 10, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi/tests: Make sure to use return values (LLVM/Clang).
parent
517f6aa5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
0 deletions
+16
-0
package.c
dlls/msi/tests/package.c
+16
-0
No files found.
dlls/msi/tests/package.c
View file @
a85adf31
...
...
@@ -753,6 +753,7 @@ static MSIHANDLE create_package_db(void)
ok
(
res
==
ERROR_SUCCESS
,
"Failed to commit database
\n
"
);
res
=
set_summary_info
(
hdb
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
res
);
res
=
run_query
(
hdb
,
"CREATE TABLE `Directory` ( "
...
...
@@ -2446,9 +2447,12 @@ static void test_formatrecord2(void)
buffer
[
0
]
=
0
;
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
r
=
MsiRecordSetString
(
hrec
,
0
,
"[foo][1]"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
r
=
MsiRecordSetString
(
hrec
,
1
,
"hoo"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
sz
==
3
,
"size wrong
\n
"
);
...
...
@@ -2456,6 +2460,7 @@ static void test_formatrecord2(void)
ok
(
r
==
ERROR_SUCCESS
,
"format failed
\n
"
);
r
=
MsiRecordSetString
(
hrec
,
0
,
"x[~]x"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
sz
==
3
,
"size wrong
\n
"
);
...
...
@@ -2463,7 +2468,9 @@ static void test_formatrecord2(void)
ok
(
r
==
ERROR_SUCCESS
,
"format failed
\n
"
);
r
=
MsiRecordSetString
(
hrec
,
0
,
"[foo.$%}][1]"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
r
=
MsiRecordSetString
(
hrec
,
1
,
"hoo"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
sz
==
3
,
"size wrong
\n
"
);
...
...
@@ -2471,6 +2478,7 @@ static void test_formatrecord2(void)
ok
(
r
==
ERROR_SUCCESS
,
"format failed
\n
"
);
r
=
MsiRecordSetString
(
hrec
,
0
,
"[
\\
[]"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
sz
==
1
,
"size wrong
\n
"
);
...
...
@@ -2479,6 +2487,7 @@ static void test_formatrecord2(void)
SetEnvironmentVariable
(
"FOO"
,
"BAR"
);
r
=
MsiRecordSetString
(
hrec
,
0
,
"[%FOO]"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
sz
==
3
,
"size wrong
\n
"
);
...
...
@@ -2486,7 +2495,9 @@ static void test_formatrecord2(void)
ok
(
r
==
ERROR_SUCCESS
,
"format failed
\n
"
);
r
=
MsiRecordSetString
(
hrec
,
0
,
"[[1]]"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
r
=
MsiRecordSetString
(
hrec
,
1
,
"%FOO"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
sz
=
sizeof
buffer
;
r
=
MsiFormatRecord
(
hpkg
,
hrec
,
buffer
,
&
sz
);
ok
(
sz
==
3
,
"size wrong
\n
"
);
...
...
@@ -8416,11 +8427,13 @@ static void test_appsearch_reglocator(void)
sprintf
(
path
,
"
\"
%s
\\
FileName1
\"
-option"
,
CURR_DIR
);
res
=
RegSetValueExA
(
hklm
,
"value16"
,
0
,
REG_SZ
,
(
const
BYTE
*
)
path
,
lstrlenA
(
path
)
+
1
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
res
);
space
=
(
strchr
(
CURR_DIR
,
' '
))
?
TRUE
:
FALSE
;
sprintf
(
path
,
"%s
\\
FileName1 -option"
,
CURR_DIR
);
res
=
RegSetValueExA
(
hklm
,
"value17"
,
0
,
REG_SZ
,
(
const
BYTE
*
)
path
,
lstrlenA
(
path
)
+
1
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
res
);
hdb
=
create_package_db
();
ok
(
hdb
,
"Expected a valid database handle
\n
"
);
...
...
@@ -9637,6 +9650,7 @@ static void test_featureparents(void)
/* msidbFeatureAttributesFavorLocal:msidbComponentAttributesOptional */
r
=
add_component_entry
(
hdb
,
"'lepus', '', 'TARGETDIR', 2, '', 'lepus_file'"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
r
=
add_feature_components_entry
(
hdb
,
"'zodiac', 'leo'"
);
ok
(
r
==
ERROR_SUCCESS
,
"cannot add feature components: %d
\n
"
,
r
);
...
...
@@ -10095,11 +10109,13 @@ static void test_installprops(void)
res
=
GetSystemMetrics
(
SM_CXSCREEN
);
size
=
MAX_PATH
;
r
=
MsiGetProperty
(
hpkg
,
"ScreenX"
,
buf
,
&
size
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
ok
(
atol
(
buf
)
==
res
,
"Expected %d, got %ld
\n
"
,
res
,
atol
(
buf
));
res
=
GetSystemMetrics
(
SM_CYSCREEN
);
size
=
MAX_PATH
;
r
=
MsiGetProperty
(
hpkg
,
"ScreenY"
,
buf
,
&
size
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS< got %d
\n
"
,
r
);
ok
(
atol
(
buf
)
==
res
,
"Expected %d, got %ld
\n
"
,
res
,
atol
(
buf
));
if
(
pGetSystemInfo
&&
pSHGetFolderPathA
)
...
...
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