Module: wine Branch: master Commit: 1c61a53ef66f65ea43bfb43e84112b981eec59bc URL: http://source.winehq.org/git/wine.git/?a=commit;h=1c61a53ef66f65ea43bfb43e84...
Author: André Hentschel nerv@dawncrow.de Date: Wed Jan 8 01:53:52 2014 +0100
kernel32/tests: Don't test last error on success.
---
dlls/kernel32/tests/console.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-)
diff --git a/dlls/kernel32/tests/console.c b/dlls/kernel32/tests/console.c index b38bb30..18d3cf9 100644 --- a/dlls/kernel32/tests/console.c +++ b/dlls/kernel32/tests/console.c @@ -1152,22 +1152,13 @@ static void test_OpenConsoleW(void) CloseHandle(ret); }
- /* OpenConsoleW should not touch the last error on success. */ - SetLastError(0xdeadbeef); ret = pOpenConsoleW(coninW, GENERIC_READ | GENERIC_WRITE, FALSE, OPEN_EXISTING); - ok(ret != INVALID_HANDLE_VALUE, - "Expected OpenConsoleW to return a valid handle\n"); - ok(GetLastError() == 0xdeadbeef, - "Expected the last error to be untouched, got %u\n", GetLastError()); + ok(ret != INVALID_HANDLE_VALUE, "Expected OpenConsoleW to return a valid handle\n"); if (ret != INVALID_HANDLE_VALUE) CloseHandle(ret);
- SetLastError(0xdeadbeef); ret = pOpenConsoleW(conoutW, GENERIC_READ | GENERIC_WRITE, FALSE, OPEN_EXISTING); - ok(ret != INVALID_HANDLE_VALUE, - "Expected OpenConsoleW to return a valid handle\n"); - ok(GetLastError() == 0xdeadbeef, - "Expected the last error to be untouched, got %u\n", GetLastError()); + ok(ret != INVALID_HANDLE_VALUE, "Expected OpenConsoleW to return a valid handle\n"); if (ret != INVALID_HANDLE_VALUE) CloseHandle(ret); }