Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
d1c8769b
Commit
d1c8769b
authored
May 14, 2010
by
Hans Leidekker
Committed by
Alexandre Julliard
May 14, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Add some tests for RtlIsTextUnicode.
parent
41e147e6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
rtlstr.c
dlls/ntdll/tests/rtlstr.c
+7
-0
No files found.
dlls/ntdll/tests/rtlstr.c
View file @
d1c8769b
...
...
@@ -1695,6 +1695,8 @@ static void test_RtlIntegerToChar(void)
static
void
test_RtlIsTextUnicode
(
void
)
{
char
ascii
[]
=
"A simple string"
;
char
false_positive
[]
=
{
0x41
,
0x0a
,
0x0d
,
0x1d
};
WCHAR
false_negative
=
0x0d0a
;
WCHAR
unicode
[]
=
{
'A'
,
' '
,
'U'
,
'n'
,
'i'
,
'c'
,
'o'
,
'd'
,
'e'
,
' '
,
's'
,
't'
,
'r'
,
'i'
,
'n'
,
'g'
,
0
};
WCHAR
unicode_no_controls
[]
=
{
'A'
,
'U'
,
'n'
,
'i'
,
'c'
,
'o'
,
'd'
,
'e'
,
's'
,
't'
,
'r'
,
'i'
,
'n'
,
'g'
,
0
};
/* String with both byte-reversed and standard Unicode control characters. */
...
...
@@ -1810,6 +1812,11 @@ static void test_RtlIsTextUnicode(void)
ok
(
!
pRtlIsTextUnicode
(
mixed_controls
,
sizeof
(
mixed_controls
),
&
flags
),
"Test should pass on string containing both byte-reversed and standard control characters.
\n
"
);
ok
(
flags
==
(
IS_TEXT_UNICODE_CONTROLS
|
IS_TEXT_UNICODE_REVERSE_CONTROLS
),
"Expected flags 0x44, obtained %x
\n
"
,
flags
);
flags
=
IS_TEXT_UNICODE_STATISTICS
;
todo_wine
ok
(
pRtlIsTextUnicode
(
false_positive
,
sizeof
(
false_positive
),
&
flags
),
"Test should pass on false positive.
\n
"
);
ok
(
!
pRtlIsTextUnicode
(
&
false_negative
,
sizeof
(
false_negative
),
NULL
),
"Test should fail on 0x0d0a (MALAYALAM LETTER UU).
\n
"
);
HeapFree
(
GetProcessHeap
(),
0
,
be_unicode
);
HeapFree
(
GetProcessHeap
(),
0
,
be_unicode_no_controls
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment