From 3bacfc300530016d234e3d7864fb0eafafba4f9b Mon Sep 17 00:00:00 2001 From: Gijs Vermeulen Date: Sun, 6 Jan 2019 04:17:54 +0100 Subject: [PATCH] wtsapi32/tests: Add WTSQueryUserToken parameter test. Signed-off-by: Gijs Vermeulen Signed-off-by: Alexandre Julliard --- dlls/wtsapi32/tests/wtsapi.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/dlls/wtsapi32/tests/wtsapi.c b/dlls/wtsapi32/tests/wtsapi.c index 341d9e605fa..c24bd491a7f 100644 --- a/dlls/wtsapi32/tests/wtsapi.c +++ b/dlls/wtsapi32/tests/wtsapi.c @@ -105,8 +105,20 @@ static void test_WTSQuerySessionInformationW(void) WTSFreeMemory(buf); } +static void test_WTSQueryUserToken(void) +{ + BOOL ret; + + SetLastError(0xdeadbeef); + ret = WTSQueryUserToken(WTS_CURRENT_SESSION, NULL); + ok(!ret, "expected WTSQueryUserToken to fail\n"); + todo_wine + ok(GetLastError()==ERROR_INVALID_PARAMETER, "expected ERROR_INVALID_PARAMETER got: %d\n", GetLastError()); +} + START_TEST (wtsapi) { test_WTSEnumerateProcessesW(); test_WTSQuerySessionInformationW(); + test_WTSQueryUserToken(); }