Commit 6c720615 authored by Paul Vriens's avatar Paul Vriens Committed by Alexandre Julliard

setupapi/tests: Fix a test failure on Vista (and skip some tests).

parent 05988f4f
...@@ -160,8 +160,9 @@ static void test_SetupCopyOEMInf(void) ...@@ -160,8 +160,9 @@ static void test_SetupCopyOEMInf(void)
res = pSetupCopyOEMInfA("", NULL, 0, SP_COPY_NOOVERWRITE, NULL, 0, NULL, NULL); res = pSetupCopyOEMInfA("", NULL, 0, SP_COPY_NOOVERWRITE, NULL, 0, NULL, NULL);
ok(res == FALSE, "Expected FALSE, got %d\n", res); ok(res == FALSE, "Expected FALSE, got %d\n", res);
ok(GetLastError() == ERROR_FILE_NOT_FOUND || ok(GetLastError() == ERROR_FILE_NOT_FOUND ||
GetLastError() == ERROR_BAD_PATHNAME, /* Win98 */ GetLastError() == ERROR_BAD_PATHNAME || /* Win98 */
"Expected ERROR_FILE_NOT_FOUND or ERROR_BAD_PATHNAME, got %d\n", GetLastError()); GetLastError() == ERROR_INVALID_PARAMETER, /* Vista, W2K8 */
"Unexpected error : %d\n", GetLastError());
/* try a relative nonexistent SourceInfFileName */ /* try a relative nonexistent SourceInfFileName */
SetLastError(0xdeadbeef); SetLastError(0xdeadbeef);
...@@ -196,6 +197,17 @@ static void test_SetupCopyOEMInf(void) ...@@ -196,6 +197,17 @@ static void test_SetupCopyOEMInf(void)
SetLastError(0xdeadbeef); SetLastError(0xdeadbeef);
res = pSetupCopyOEMInfA(tmpfile, NULL, 0, SP_COPY_NOOVERWRITE, NULL, 0, NULL, NULL); res = pSetupCopyOEMInfA(tmpfile, NULL, 0, SP_COPY_NOOVERWRITE, NULL, 0, NULL, NULL);
ok(res == FALSE, "Expected FALSE, got %d\n", res); ok(res == FALSE, "Expected FALSE, got %d\n", res);
if (GetLastError() == ERROR_WRONG_INF_TYPE)
{
/* FIXME:
* Vista needs a [Manufacturer] entry in the inf file. Doing this will give some
* popups during the installation though as it also needs a catalog file (signed?).
*/
win_skip("Needs a different inf file on Vista/W2K8\n");
DeleteFile(tmpfile);
return;
}
ok(GetLastError() == ERROR_FILE_NOT_FOUND || ok(GetLastError() == ERROR_FILE_NOT_FOUND ||
GetLastError() == ERROR_FILE_EXISTS, /* Win98 */ GetLastError() == ERROR_FILE_EXISTS, /* Win98 */
"Expected ERROR_FILE_NOT_FOUND or ERROR_FILE_EXISTS, got %d\n", GetLastError()); "Expected ERROR_FILE_NOT_FOUND or ERROR_FILE_EXISTS, got %d\n", GetLastError());
......
...@@ -1214,6 +1214,7 @@ DECL_WINELIB_SETUPAPI_TYPE_AW(PSP_INF_SIGNER_INFO) ...@@ -1214,6 +1214,7 @@ DECL_WINELIB_SETUPAPI_TYPE_AW(PSP_INF_SIGNER_INFO)
#define ERROR_SET_SYSTEM_RESTORE_POINT (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x236) #define ERROR_SET_SYSTEM_RESTORE_POINT (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x236)
#define ERROR_INCORRECTLY_COPIED_INF (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x237) #define ERROR_INCORRECTLY_COPIED_INF (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x237)
#define ERROR_SCE_DISABLED (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x238) #define ERROR_SCE_DISABLED (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x238)
#define ERROR_WRONG_INF_TYPE (APPLICATION_ERROR_MASK|ERROR_SEVERITY_ERROR|0x24A)
#define ERROR_NO_DEFAULT_INTERFACE_DEVICE ERROR_NO_DEFAULT_DEVICE_INTERFACE #define ERROR_NO_DEFAULT_INTERFACE_DEVICE ERROR_NO_DEFAULT_DEVICE_INTERFACE
#define ERROR_INTERFACE_DEVICE_ACTIVE ERROR_DEVICE_INTERFACE_ACTIVE #define ERROR_INTERFACE_DEVICE_ACTIVE ERROR_DEVICE_INTERFACE_ACTIVE
#define ERROR_INTERFACE_DEVICE_REMOVED ERROR_DEVICE_INTERFACE_REMOVED #define ERROR_INTERFACE_DEVICE_REMOVED ERROR_DEVICE_INTERFACE_REMOVED
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment