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
e6d126cd
Commit
e6d126cd
authored
Jun 23, 2008
by
James Hawkins
Committed by
Alexandre Julliard
Jun 24, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Test the PublishProduct action with the machine context.
parent
cdb33f8a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
89 additions
and
0 deletions
+89
-0
install.c
dlls/msi/tests/install.c
+89
-0
No files found.
dlls/msi/tests/install.c
View file @
e6d126cd
...
...
@@ -2481,6 +2481,8 @@ static void test_publish_publishproduct(void)
static
const
CHAR
badprod
[]
=
"Software
\\
Microsoft
\\
Windows
\\
CurrentVersion"
"
\\
Installer
\\
Products"
"
\\
84A88FD7F6998CE40A22FB59F6B9C2BB"
;
static
const
CHAR
machprod
[]
=
"Installer
\\
Products
\\
84A88FD7F6998CE40A22FB59F6B9C2BB"
;
static
const
CHAR
machup
[]
=
"Installer
\\
UpgradeCodes
\\
51AAE0C44620A5E4788506E91F249BD2"
;
get_user_sid
(
&
usersid
);
if
(
!
usersid
)
...
...
@@ -2576,6 +2578,93 @@ static void test_publish_publishproduct(void)
RegDeleteKeyA
(
hkey
,
""
);
RegCloseKey
(
hkey
);
/* PublishProduct, machine */
r
=
MsiInstallProductA
(
msifile
,
"PUBLISH_PRODUCT=1 ALLUSERS=1"
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
ok
(
delete_pf
(
"msitest
\\
maximus"
,
TRUE
),
"File not installed
\n
"
);
ok
(
delete_pf
(
"msitest"
,
FALSE
),
"File not installed
\n
"
);
res
=
RegOpenKeyA
(
HKEY_LOCAL_MACHINE
,
badprod
,
&
hkey
);
ok
(
res
==
ERROR_FILE_NOT_FOUND
,
"Expected ERROR_FILE_NOT_FOUND, got %d
\n
"
,
res
);
sprintf
(
keypath
,
prodpath
,
"S-1-5-18"
);
res
=
RegOpenKeyA
(
HKEY_LOCAL_MACHINE
,
keypath
,
&
hkey
);
todo_wine
{
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
}
res
=
RegOpenKeyA
(
hkey
,
"InstallProperties"
,
&
props
);
todo_wine
{
ok
(
res
==
ERROR_FILE_NOT_FOUND
,
"Expected ERROR_FILE_NOT_FOUND, got %d
\n
"
,
res
);
}
res
=
RegOpenKeyA
(
hkey
,
"Patches"
,
&
patches
);
todo_wine
{
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
CHECK_DEL_REG_STR
(
patches
,
"AllPatches"
,
NULL
);
}
RegDeleteKeyA
(
patches
,
""
);
RegCloseKey
(
patches
);
RegDeleteKeyA
(
hkey
,
""
);
RegCloseKey
(
hkey
);
res
=
RegOpenKeyA
(
HKEY_CLASSES_ROOT
,
machprod
,
&
hkey
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
CHECK_DEL_REG_STR
(
hkey
,
"ProductName"
,
"MSITEST"
);
CHECK_DEL_REG_STR
(
hkey
,
"PackageCode"
,
"AC75740029052c94DA02821EECD05F2F"
);
CHECK_DEL_REG_DWORD
(
hkey
,
"Language"
,
1033
);
CHECK_DEL_REG_DWORD
(
hkey
,
"Version"
,
0x1010001
);
CHECK_DEL_REG_DWORD
(
hkey
,
"AuthorizedLUAApp"
,
0
);
todo_wine
CHECK_DEL_REG_DWORD
(
hkey
,
"Assignment"
,
1
);
CHECK_DEL_REG_DWORD
(
hkey
,
"AdvertiseFlags"
,
0x184
);
CHECK_DEL_REG_DWORD
(
hkey
,
"InstanceType"
,
0
);
CHECK_DEL_REG_STR
(
hkey
,
"Clients"
,
":"
);
res
=
RegOpenKeyA
(
hkey
,
"SourceList"
,
&
sourcelist
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
lstrcpyA
(
path
,
"n;1;"
);
lstrcatA
(
path
,
temp
);
CHECK_DEL_REG_STR
(
sourcelist
,
"LastUsedSource"
,
path
);
CHECK_DEL_REG_STR
(
sourcelist
,
"PackageName"
,
"msitest.msi"
);
res
=
RegOpenKeyA
(
sourcelist
,
"Net"
,
&
net
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
CHECK_DEL_REG_STR
(
net
,
"1"
,
temp
);
RegDeleteKeyA
(
net
,
""
);
RegCloseKey
(
net
);
res
=
RegOpenKeyA
(
sourcelist
,
"Media"
,
&
media
);
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
CHECK_DEL_REG_STR
(
media
,
"1"
,
"DISK1;"
);
RegDeleteKeyA
(
media
,
""
);
RegCloseKey
(
media
);
RegDeleteKeyA
(
sourcelist
,
""
);
RegCloseKey
(
sourcelist
);
RegDeleteKeyA
(
hkey
,
""
);
RegCloseKey
(
hkey
);
res
=
RegOpenKeyA
(
HKEY_CLASSES_ROOT
,
machup
,
&
hkey
);
todo_wine
{
ok
(
res
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
res
);
CHECK_DEL_REG_STR
(
hkey
,
"84A88FD7F6998CE40A22FB59F6B9C2BB"
,
NULL
);
}
RegDeleteKeyA
(
hkey
,
""
);
RegCloseKey
(
hkey
);
DeleteFile
(
msifile
);
DeleteFile
(
"msitest
\\
maximus"
);
RemoveDirectory
(
"msitest"
);
...
...
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