advpack/tests: Remove win9x hacks.
This commit is contained in:
parent
4bf211714e
commit
befe57aa14
|
@ -109,9 +109,7 @@ static void test_RunSetupCommand(void)
|
||||||
/* try to run an exe with the RSC_FLAG_INF flag */
|
/* try to run an exe with the RSC_FLAG_INF flag */
|
||||||
hexe = (HANDLE)0xdeadbeef;
|
hexe = (HANDLE)0xdeadbeef;
|
||||||
hr = pRunSetupCommand(NULL, "winver.exe", "Install", systemdir, "Title", &hexe, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
hr = pRunSetupCommand(NULL, "winver.exe", "Install", systemdir, "Title", &hexe, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
ok(is_spapi_err(hr) ||
|
ok(is_spapi_err(hr), "Expected a setupapi error, got %d\n", 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(hexe == (HANDLE)0xdeadbeef, "Expected hexe to be 0xdeadbeef\n");
|
||||||
ok(!TerminateProcess(hexe, 0), "Expected TerminateProcess to fail\n");
|
ok(!TerminateProcess(hexe, 0), "Expected TerminateProcess to fail\n");
|
||||||
|
|
||||||
|
@ -144,9 +142,7 @@ static void test_RunSetupCommand(void)
|
||||||
|
|
||||||
/* try a relative path to the INF, with working dir provided */
|
/* 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);
|
hr = pRunSetupCommand(NULL, "one\\test.inf", "DefaultInstall", dir, "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
ok(hr == ERROR_SUCCESS ||
|
ok(hr == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", hr);
|
||||||
hr == E_FAIL, /* win9x */
|
|
||||||
"Expected ERROR_SUCCESS, got %d\n", hr);
|
|
||||||
|
|
||||||
/* try a relative path to the INF, NULL working dir */
|
/* 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);
|
hr = pRunSetupCommand(NULL, "one\\test.inf", "DefaultInstall", NULL, "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
|
@ -155,15 +151,11 @@ static void test_RunSetupCommand(void)
|
||||||
|
|
||||||
/* try a relative path to the INF, empty working dir */
|
/* 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);
|
hr = pRunSetupCommand(NULL, "one\\test.inf", "DefaultInstall", "", "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
ok(hr == ERROR_SUCCESS ||
|
ok(hr == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", hr);
|
||||||
hr == E_FAIL, /* win9x */
|
|
||||||
"Expected ERROR_SUCCESS or E_FAIL, got %d\n", hr);
|
|
||||||
|
|
||||||
/* try only the INF filename, with working dir provided */
|
/* 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);
|
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) ||
|
ok(hr == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), "Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d\n", hr);
|
||||||
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 */
|
/* try only the INF filename, NULL working dir */
|
||||||
hr = pRunSetupCommand(NULL, "test.inf", "DefaultInstall", NULL, "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
hr = pRunSetupCommand(NULL, "test.inf", "DefaultInstall", NULL, "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
|
@ -172,9 +164,7 @@ static void test_RunSetupCommand(void)
|
||||||
|
|
||||||
/* try only the INF filename, empty working dir */
|
/* try only the INF filename, empty working dir */
|
||||||
hr = pRunSetupCommand(NULL, "test.inf", "DefaultInstall", "", "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
hr = pRunSetupCommand(NULL, "test.inf", "DefaultInstall", "", "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
ok(hr == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) ||
|
ok(hr == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), "Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d\n", hr);
|
||||||
hr == E_FAIL, /* win9x */
|
|
||||||
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) or E_FAIL, got %d\n", hr);
|
|
||||||
|
|
||||||
DeleteFileA("one\\test.inf");
|
DeleteFileA("one\\test.inf");
|
||||||
RemoveDirectoryA("one");
|
RemoveDirectoryA("one");
|
||||||
|
@ -183,9 +173,7 @@ static void test_RunSetupCommand(void)
|
||||||
|
|
||||||
/* try INF file in the current directory, working directory provided */
|
/* 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);
|
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) ||
|
ok(hr == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), "Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d\n", hr);
|
||||||
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 */
|
/* 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);
|
hr = pRunSetupCommand(NULL, "test.inf", "DefaultInstall", NULL, "Title", NULL, RSC_FLAG_INF | RSC_FLAG_QUIET, NULL);
|
||||||
|
@ -194,9 +182,7 @@ static void test_RunSetupCommand(void)
|
||||||
|
|
||||||
/* try INF file in the current directory, empty working directory */
|
/* 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);
|
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) ||
|
ok(hr == HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), "Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND), got %d\n", hr);
|
||||||
hr == E_FAIL, /* win9x */
|
|
||||||
"Expected HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND) or E_FAIL, got %d\n", hr);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void test_LaunchINFSection(void)
|
static void test_LaunchINFSection(void)
|
||||||
|
|
Loading…
Reference in New Issue