msvcp90/tests: Fixed _Getctype tests.

This commit is contained in:
Piotr Caban 2012-07-02 18:32:05 +02:00 committed by Alexandre Julliard
parent 8a15e426b3
commit e16922f3f3
1 changed files with 6 additions and 5 deletions

View File

@ -58,7 +58,7 @@ static BYTE (__cdecl *p_short_eq)(const void*, const void*);
static char* (__cdecl *p_Copy_s)(char*, size_t, const char*, size_t);
static unsigned short (__cdecl *p_wctype)(const char*);
static MSVCP__Ctypevec (__cdecl *p__Getctype)(void);
static MSVCP__Ctypevec* (__cdecl *p__Getctype)(MSVCP__Ctypevec*);
#undef __thiscall
#ifdef __i386__
@ -362,16 +362,16 @@ static void test__Getctype(void)
{
MSVCP__Ctypevec ret;
ret = p__Getctype();
ok(p__Getctype(&ret) == &ret, "__Getctype returned incorrect pointer\n");
ok(ret.handle == 0, "ret.handle = %d\n", ret.handle);
ok(ret.page == 0, "ret.page = %d\n", ret.page);
ok(ret.delfl == 1, "ret.delfl = %d\n", ret.delfl);
ok(ret.table[0] == 32, "ret.table[0] = %d\n", ret.table[0]);
p_free(ret.table);
p__get_current_locale()->locinfo->lc_handle[LC_COLLATE] = 1;
ret = p__Getctype();
ok(ret.handle == 1, "ret.handle = %d\n", ret.handle);
p__get_current_locale()->locinfo->lc_handle[LC_COLLATE] = 0x1234567;
ok(p__Getctype(&ret) == &ret, "__Getctype returned incorrect pointer\n");
ok(ret.handle == 0x1234567, "ret.handle = %d\n", ret.handle);
ok(ret.page == 0, "ret.page = %d\n", ret.page);
ok(ret.delfl == 1, "ret.delfl = %d\n", ret.delfl);
ok(ret.table[0] == 32, "ret.table[0] = %d\n", ret.table[0]);
@ -418,6 +418,7 @@ static void test_virtual_call(void)
char str2[] = "TEST";
int ret;
p__get_current_locale()->locinfo->lc_handle[LC_COLLATE] = 1;
call_func2(p_collate_char_ctor_refs, this, 0);
ret = (int)call_func5(p_collate_char_compare, this, str1, str1+4, str1, str1+4);
ok(ret == 0, "collate<char>::compare returned %d\n", ret);