35 {
"%I64X", ((
ULONGLONG)0x12345 << 32) | 0x67890a,
"123450067890A" },
36 {
"%I32X", ((
ULONGLONG)0x12345 << 32) | 0x67890a,
"67890A" },
37 {
"%I64d", (
ULONGLONG)543210 * 1000000,
"543210000000" },
38 {
"%I64X", (
LONGLONG)-0x12345,
"FFFFFFFFFFFEDCBB" },
39 {
"%I32x", (
LONGLONG)-0x12345,
"fffedcbb" },
40 {
"%I64u", (
LONGLONG)-123,
"18446744073709551493" },
41 {
"%Id", (
LONGLONG)-12345,
"-12345" },
43 {
"%Ix", ((
ULONGLONG)0x12345 << 32) | 0x67890a,
"123450067890a" },
44 {
"%Ix", (
LONGLONG)-0x12345,
"fffffffffffedcbb" },
45 {
"%p", (
LONGLONG)-0x12345,
"FFFFFFFFFFFEDCBB" },
47 {
"%Ix", ((
ULONGLONG)0x12345 << 32) | 0x67890a,
"67890a" },
48 {
"%Ix", (
LONGLONG)-0x12345,
"fffedcbb" },
49 {
"%p", (
LONGLONG)-0x12345,
"FFFEDCBB" },
55 char buf[25],
star[4], partial[4];
57 static const WCHAR fffeW[] =
L"\xfffe";
66 {
starW,
"%.1S", partial, 1 },
69 { fffeW,
"%.1S",
"?", 1 },
70 { fffeW,
"%.2S",
"?", 1 },
71 {
wineW,
"%.2S",
"??", 2 },
72 {
star,
"%.1s", partial, 1 },
73 { (
void *)0x2606,
"%2C",
star, 2 },
74 { (
void *)0xfffd,
"%C",
"?", 1 },
75 { (
void *)0xe199,
"%2c",
" \x99", 2 },
82 ok(rc == 10,
"wsprintfA length failure: rc=%d error=%ld\n",rc,
GetLastError());
84 "wsprintfA zero padded negative value failure: buf=[%s]\n",
buf);
88 win_skip(
"I64 formats not supported\n" );
100 skip(
"Multi-byte wsprintfA test isn't available for the current codepage\n");
105 ok(rc == 3,
"unexpected rc, got %d\n", rc);
106 partial[0] =
star[0];
114 ok(rc == testcase[
i].rc,
115 "%u: expected %d, got %d\n",
116 i, testcase[
i].rc, rc);
119 "%u: expected %s, got %s\n",
136 WCHAR def_spc[] =
L"*?\x2605 ";
138 char stars_mb[8], partial00[8], partialFF[8];
146 { stars_mb,
L"%.3S",
stars, 3 },
147 { partial00,
L"%-4S",
L"*\0 ", 4 },
148 { partialFF,
L"%-4S", def_spc, 4 },
157 win_skip(
"wsprintfW is not implemented\n");
160 ok(rc == 10,
"wsPrintfW length failure: rc=%d error=%ld\n",rc,
GetLastError());
162 "wsprintfW zero padded negative value failure\n");
166 win_skip(
"I64 formats not supported\n" );
174 ok(rc ==
lstrlenW(
res),
"%u: wsprintfW length failure: rc=%d\n",
i, rc);
179 ok(rc == 2,
"expected 2, got %d\n", rc);
180 ok(
buf[0] ==
L' ',
"expected \\x0020, got \\x%04x\n",
buf[0]);
181 ok(
buf[1] ==
L'*',
"expected \\x%04x, got \\x%04x\n",
L'*',
buf[1]);
184 ok(rc == 1,
"expected 1, got %d\n", rc);
185 ok(
buf[0] ==
L'\x2605',
"expected \\x%04x, got \\x%04x\n",
L'\x2605',
buf[0]);
189 ok(rc == 1,
"expected 1, got %d\n", rc);
190 ok(
buf[0] == wcA1,
"expected \\x%04x, got \\x%04x\n", wcA1,
buf[0]);
193 ok(rc == 1,
"expected 1, got %d\n", rc);
194 ok(
buf[0] == wcA1,
"expected \\x%04x, got \\x%04x\n", wcA1,
buf[0]);
198 ok(rc == 2,
"expected 1, got %d\n", rc);
199 ok(
buf[0] ==
L' ',
"expected \\x0020, got \\x%04x\n",
buf[0]);
200 ok(
buf[1] == wc99,
"expected \\x%04x, got \\x%04x\n", wc99,
buf[1]);
204 skip(
"Multi-byte wsprintfW test isn't available for the current codepage\n");
210 ok(rc == 6,
"expected 6, got %d\n", rc);
211 strcpy(partial00, stars_mb);
213 strcpy(partialFF, stars_mb);
221 ok(rc == testcase[
i].rc,
222 "%u: expected %d, got %d\n",
223 i, testcase[
i].rc, rc);
226 "%u: expected %s, got %s\n",
i,
243 if ((
out >> 16) != 0)
249 ok(!failed,
"CharUpper failed - 16bit input (0x%0Ix) returned 32bit result (0x%0Ix)\n",
i,
out);
260 if ((
out >> 16) != 0)
266 ok(!failed,
"CharLower failed - 16bit input (0x%0Ix) returned 32bit result (0x%0Ix)\n",
i,
out);
const char * wine_dbgstr_an(const char *str, int n)
#define ERROR_CALL_NOT_IMPLEMENTED
#define WideCharToMultiByte
#define MultiByteToWideChar
BOOL WINAPI IsDBCSLeadByte(BYTE testchar)
int WINAPI lstrcmpW(LPCWSTR str1, LPCWSTR str2)
BOOL WINAPI GetCPInfoExW(UINT codepage, DWORD dwFlags, LPCPINFOEXW cpinfo)
BOOL WINAPI GetCPInfo(UINT codepage, LPCPINFO cpinfo)
int WINAPI lstrcmpA(LPCSTR str1, LPCSTR str2)
LPSTR WINAPI CharLowerA(char *str)
LPSTR WINAPI CharUpperA(LPSTR str)
_ACRTIMP int __cdecl memcmp(const void *, const void *, size_t)
_ACRTIMP size_t __cdecl strlen(const char *)
_ACRTIMP int __cdecl strcmp(const char *, const char *)
GLenum GLuint GLenum GLsizei const GLchar * buf
GLenum GLenum GLenum input
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
static void wsprintfATest(void)
static WCHAR my_btowc(BYTE c)
static void CharLowerTest(void)
static const struct @1869 i64_formats[]
static void CharUpperTest(void)
static void wsprintfWTest(void)
const char int int int static __inline const char * wine_dbgstr_a(const char *s)
static const WCHAR starW[]
wchar_t tm const _CrtWcstime_Writes_and_advances_ptr_ count wchar_t ** out
DWORD WINAPI GetLastError(void)
int WINAPIV wsprintfW(_Out_ LPWSTR, _In_ _Printf_format_string_ LPCWSTR,...)
int WINAPIV wsprintfA(_Out_ LPSTR, _In_ _Printf_format_string_ LPCSTR,...)