2
WCSCOLL: int wcscoll (const wchar_t *ws1, const wchar_t *ws2);
5
#define TST_FUNCTION wcscoll
7
#include "tsp_common.c"
8
#include "dat_wcscoll.c"
11
tst_wcscoll (FILE * fp, int debug_flg)
19
TST_HEAD_LOCALE (wcscoll, S_WCSCOLL);
22
TST_GET_ERRET (wcscoll);
23
ws1 = TST_INPUT (wcscoll).ws1; /* external value: size WCSSIZE */
24
ws2 = TST_INPUT (wcscoll).ws2;
27
ret = wcscoll (ws1, ws2);
32
fprintf (stderr, "tst_wcscoll: ret = %d\n", ret);
35
cmp = TST_EXPECT (wcscoll).cmp_flg;
36
TST_IF_RETURN (S_WCSCOLL)
40
if ((cmp == 1 && ret > 0) || (cmp == -1 && ret < 0))
42
Result (C_SUCCESS, S_WCSCOLL, CASE_3, MS_PASSED);
50
Result (C_FAILURE, S_WCSCOLL, CASE_3,
51
"the return value should be positive"
54
Result (C_FAILURE, S_WCSCOLL, CASE_3,
55
"the return value should be positive"
56
" but it's negative.");
61
Result (C_FAILURE, S_WCSCOLL, CASE_3,
62
"the return value should be negative"
65
Result (C_FAILURE, S_WCSCOLL, CASE_3,
66
"the return value should be negative"
67
" but it's positive.");