netapi32/tests: Fix workstation test failures on XP.
This commit is contained in:
parent
5c1e6cf7cd
commit
1e6ffc9c32
|
@ -79,12 +79,17 @@ static void run_wkstausergetinfo_tests(void)
|
||||||
LPWKSTA_USER_INFO_1 ui1 = NULL;
|
LPWKSTA_USER_INFO_1 ui1 = NULL;
|
||||||
LPWKSTA_USER_INFO_1101 ui1101 = NULL;
|
LPWKSTA_USER_INFO_1101 ui1101 = NULL;
|
||||||
DWORD dwSize;
|
DWORD dwSize;
|
||||||
|
NET_API_STATUS rc;
|
||||||
|
|
||||||
/* Level 0 */
|
/* Level 0 */
|
||||||
ok(pNetWkstaUserGetInfo(NULL, 0, (LPBYTE *)&ui0) == NERR_Success,
|
rc = pNetWkstaUserGetInfo(NULL, 0, (LPBYTE *)&ui0);
|
||||||
"NetWkstaUserGetInfo is unsuccessful\n");
|
if (rc == NERR_WkstaNotStarted)
|
||||||
|
{
|
||||||
|
skip("Workstation service not running\n");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
ok(!rc && ui0, "got %d and %p (expected NERR_Success and != NULL\n", rc, ui0);
|
||||||
|
|
||||||
ok(ui0 != NULL, "ui0 is NULL\n");
|
|
||||||
/* This failure occurred when I ran sshd as service and didn't authenticate
|
/* This failure occurred when I ran sshd as service and didn't authenticate
|
||||||
* Since the test dereferences ui0, the rest of this test is worthless
|
* Since the test dereferences ui0, the rest of this test is worthless
|
||||||
*/
|
*/
|
||||||
|
@ -168,7 +173,7 @@ static void run_wkstatransportenum_tests(void)
|
||||||
/* final check: valid return, actually get data back */
|
/* final check: valid return, actually get data back */
|
||||||
apiReturn = pNetWkstaTransportEnum(NULL, 0, &bufPtr, MAX_PREFERRED_LENGTH,
|
apiReturn = pNetWkstaTransportEnum(NULL, 0, &bufPtr, MAX_PREFERRED_LENGTH,
|
||||||
&entriesRead, &totalEntries, NULL);
|
&entriesRead, &totalEntries, NULL);
|
||||||
ok(apiReturn == NERR_Success || apiReturn == ERROR_NETWORK_UNREACHABLE,
|
ok(apiReturn == NERR_Success || apiReturn == ERROR_NETWORK_UNREACHABLE || apiReturn == NERR_WkstaNotStarted,
|
||||||
"NetWkstaTransportEnum returned %d\n", apiReturn);
|
"NetWkstaTransportEnum returned %d\n", apiReturn);
|
||||||
if (apiReturn == NERR_Success) {
|
if (apiReturn == NERR_Success) {
|
||||||
/* WKSTA_TRANSPORT_INFO_0 *transports = (WKSTA_TRANSPORT_INFO_0 *)bufPtr; */
|
/* WKSTA_TRANSPORT_INFO_0 *transports = (WKSTA_TRANSPORT_INFO_0 *)bufPtr; */
|
||||||
|
|
Loading…
Reference in New Issue