Commit 22143816 authored by Qian Hong's avatar Qian Hong Committed by Alexandre Julliard

imm32/tests: Added test for IMCC lock count.

parent 44f60067
...@@ -712,6 +712,28 @@ static void test_ImmGetIMCLockCount(void) ...@@ -712,6 +712,28 @@ static void test_ImmGetIMCLockCount(void)
ImmDestroyContext(imc); ImmDestroyContext(imc);
} }
static void test_ImmGetIMCCLockCount(void)
{
HIMCC imcc;
DWORD count, ret;
imcc = ImmCreateIMCC(sizeof(CANDIDATEINFO));
count = ImmGetIMCCLockCount(imcc);
ok(count == 0, "expect 0, returned %d\n", count);
ImmLockIMCC(imcc);
count = ImmGetIMCCLockCount(imcc);
ok(count == 1, "expect 1, returned %d\n", count);
ret = ImmUnlockIMCC(imcc);
ok(ret == FALSE, "expect FALSE, ret %d\n", ret);
count = ImmGetIMCCLockCount(imcc);
ok(count == 0, "expect 0, returned %d\n", count);
ret = ImmUnlockIMCC(imcc);
todo_wine ok(ret == FALSE, "expect FALSE, ret %d\n", ret);
count = ImmGetIMCCLockCount(imcc);
todo_wine ok(count == 0, "expect 0, returned %d\n", count);
ImmDestroyIMCC(imcc);
}
static void test_ImmMessages(void) static void test_ImmMessages(void)
{ {
CANDIDATEFORM cf; CANDIDATEFORM cf;
...@@ -872,6 +894,7 @@ START_TEST(imm32) { ...@@ -872,6 +894,7 @@ START_TEST(imm32) {
test_ImmGetDescription(); test_ImmGetDescription();
test_ImmDefaultHwnd(); test_ImmDefaultHwnd();
test_ImmGetIMCLockCount(); test_ImmGetIMCLockCount();
test_ImmGetIMCCLockCount();
msg_spy_cleanup(); msg_spy_cleanup();
/* Reinitialize the hooks to capture all windows */ /* Reinitialize the hooks to capture all windows */
msg_spy_init(NULL); msg_spy_init(NULL);
......
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