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
10a1b948
Commit
10a1b948
authored
Jun 29, 2008
by
James Hawkins
Committed by
Alexandre Julliard
Jun 30, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
advpack: Fix several test failures in win9x.
parent
8cfb50e5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
14 deletions
+22
-14
install.c
dlls/advpack/tests/install.c
+22
-14
No files found.
dlls/advpack/tests/install.c
View file @
10a1b948
...
...
@@ -73,9 +73,7 @@ static void create_inf_file(LPCSTR filename)
append_str
(
&
ptr
,
"Signature=
\"
$Chicago$
\"\n
"
);
append_str
(
&
ptr
,
"AdvancedINF=2.5
\n
"
);
append_str
(
&
ptr
,
"[DefaultInstall]
\n
"
);
append_str
(
&
ptr
,
"RegisterOCXs=RegisterOCXsSection
\n
"
);
append_str
(
&
ptr
,
"[RegisterOCXsSection]
\n
"
);
append_str
(
&
ptr
,
"%%11%%
\\
ole32.dll
\n
"
);
append_str
(
&
ptr
,
"CheckAdminRights=1
\n
"
);
WriteFile
(
hf
,
data
,
ptr
-
data
,
&
dwNumberOfBytesWritten
,
NULL
);
CloseHandle
(
hf
);
...
...
@@ -118,7 +116,9 @@ static void test_RunSetupCommand(void)
/* try to run an exe with the RSC_FLAG_INF flag */
hexe
=
(
HANDLE
)
0xdeadbeef
;
hr
=
pRunSetupCommand
(
NULL
,
"winver.exe"
,
"Install"
,
systemdir
,
"Title"
,
&
hexe
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
is_spapi_err
(
hr
),
"Expected a setupapi error, got %d
\n
"
,
hr
);
ok
(
is_spapi_err
(
hr
)
||
hr
==
E_FAIL
,
/* win9x */
"Expected a setupapi error or E_FAIL, got %d
\n
"
,
hr
);
ok
(
hexe
==
(
HANDLE
)
0xdeadbeef
,
"Expected hexe to be 0xdeadbeef
\n
"
);
ok
(
!
TerminateProcess
(
hexe
,
0
),
"Expected TerminateProcess to fail
\n
"
);
...
...
@@ -151,7 +151,9 @@ static void test_RunSetupCommand(void)
/* try a relative path to the INF, with working dir provided */
hr
=
pRunSetupCommand
(
NULL
,
"one
\\
test.inf"
,
"DefaultInstall"
,
dir
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
hr
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
hr
);
ok
(
hr
==
ERROR_SUCCESS
||
hr
==
E_FAIL
,
/* win9x */
"Expected ERROR_SUCCESS, got %d
\n
"
,
hr
);
/* try a relative path to the INF, NULL working dir */
hr
=
pRunSetupCommand
(
NULL
,
"one
\\
test.inf"
,
"DefaultInstall"
,
NULL
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
...
...
@@ -160,12 +162,15 @@ static void test_RunSetupCommand(void)
/* try a relative path to the INF, empty working dir */
hr
=
pRunSetupCommand
(
NULL
,
"one
\\
test.inf"
,
"DefaultInstall"
,
""
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
hr
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
hr
);
ok
(
hr
==
ERROR_SUCCESS
||
hr
==
E_FAIL
,
/* win9x */
"Expected ERROR_SUCCESS or E_FAIL, got %d
\n
"
,
hr
);
/* try only the INF filename, with working dir provided */
hr
=
pRunSetupCommand
(
NULL
,
"test.inf"
,
"DefaultInstall"
,
dir
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
),
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d
\n
"
,
hr
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
)
||
hr
==
E_FAIL
,
/* win9x */
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) or E_FAIL, got %d
\n
"
,
hr
);
/* try only the INF filename, NULL working dir */
hr
=
pRunSetupCommand
(
NULL
,
"test.inf"
,
"DefaultInstall"
,
NULL
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
...
...
@@ -174,8 +179,9 @@ static void test_RunSetupCommand(void)
/* try only the INF filename, empty working dir */
hr
=
pRunSetupCommand
(
NULL
,
"test.inf"
,
"DefaultInstall"
,
""
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
),
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d
\n
"
,
hr
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
)
||
hr
==
E_FAIL
,
/* win9x */
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) or E_FAIL, got %d
\n
"
,
hr
);
DeleteFileA
(
"one
\\
test.inf"
);
RemoveDirectoryA
(
"one"
);
...
...
@@ -184,8 +190,9 @@ static void test_RunSetupCommand(void)
/* try INF file in the current directory, working directory provided */
hr
=
pRunSetupCommand
(
NULL
,
"test.inf"
,
"DefaultInstall"
,
CURR_DIR
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
),
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d
\n
"
,
hr
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
)
||
hr
==
E_FAIL
,
/* win9x */
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) or E_FAIL, got %d
\n
"
,
hr
);
/* try INF file in the current directory, NULL working directory */
hr
=
pRunSetupCommand
(
NULL
,
"test.inf"
,
"DefaultInstall"
,
NULL
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
...
...
@@ -194,8 +201,9 @@ static void test_RunSetupCommand(void)
/* try INF file in the current directory, empty working directory */
hr
=
pRunSetupCommand
(
NULL
,
"test.inf"
,
"DefaultInstall"
,
CURR_DIR
,
"Title"
,
NULL
,
RSC_FLAG_INF
|
RSC_FLAG_QUIET
,
NULL
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
),
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d
\n
"
,
hr
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_FILE_NOT_FOUND
)
||
hr
==
E_FAIL
,
/* win9x */
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) or E_FAIL, got %d
\n
"
,
hr
);
}
static
void
test_LaunchINFSection
(
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