oleaut32/tests: Basic test for invalid arguments in LoadTypeLib/LoadTypeLibEx.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Nikolay Sivov 2017-06-07 00:29:38 +03:00 committed by Alexandre Julliard
parent cf45f3bcc8
commit 19b944d49c
1 changed files with 16 additions and 0 deletions

View File

@ -4996,6 +4996,22 @@ static void test_LoadTypeLib(void)
hres = LoadTypeLib(kernel32_dllW, &tl);
ok(hres == TYPE_E_CANTLOADLIBRARY, "LoadTypeLib returned: %08x, expected TYPE_E_CANTLOADLIBRARY\n", hres);
hres = LoadTypeLib(NULL, NULL);
ok(hres == E_INVALIDARG, "Got %#x.\n", hres);
tl = (void *)0xdeadbeef;
hres = LoadTypeLib(NULL, &tl);
ok(hres == E_INVALIDARG, "Got %#x.\n", hres);
ok(tl == (void *)0xdeadbeef, "Got %p.\n", tl);
hres = LoadTypeLibEx(NULL, REGKIND_NONE, NULL);
ok(hres == E_INVALIDARG, "Got %#x.\n", hres);
tl = (void *)0xdeadbeef;
hres = LoadTypeLibEx(NULL, REGKIND_NONE, &tl);
ok(hres == E_INVALIDARG, "Got %#x.\n", hres);
ok(tl == (void *)0xdeadbeef, "Got %p.\n", tl);
}
static void test_SetVarHelpContext(void)