Lines Matching refs:columnWidthUTF8

18 TEST(Unicode, columnWidthUTF8) {  in TEST()  argument
19 EXPECT_EQ(0, columnWidthUTF8("")); in TEST()
20 EXPECT_EQ(1, columnWidthUTF8(" ")); in TEST()
21 EXPECT_EQ(1, columnWidthUTF8("a")); in TEST()
22 EXPECT_EQ(1, columnWidthUTF8("~")); in TEST()
24 EXPECT_EQ(6, columnWidthUTF8("abcdef")); in TEST()
26 EXPECT_EQ(-1, columnWidthUTF8("\x01")); in TEST()
27 EXPECT_EQ(-1, columnWidthUTF8("aaaaaaaaaa\x01")); in TEST()
28 EXPECT_EQ(-1, columnWidthUTF8("\342\200\213")); // 200B ZERO WIDTH SPACE in TEST()
34 EXPECT_EQ(1, columnWidthUTF8("\302\255")); in TEST()
36 EXPECT_EQ(0, columnWidthUTF8("\314\200")); // 0300 COMBINING GRAVE ACCENT in TEST()
37 EXPECT_EQ(1, columnWidthUTF8("\340\270\201")); // 0E01 THAI CHARACTER KO KAI in TEST()
38 EXPECT_EQ(2, columnWidthUTF8("\344\270\200")); // CJK UNIFIED IDEOGRAPH-4E00 in TEST()
40 EXPECT_EQ(4, columnWidthUTF8("\344\270\200\344\270\200")); in TEST()
41 EXPECT_EQ(3, columnWidthUTF8("q\344\270\200")); in TEST()
42 EXPECT_EQ(3, columnWidthUTF8("\314\200\340\270\201\344\270\200")); in TEST()
45 EXPECT_EQ(-2, columnWidthUTF8("\344")); in TEST()
46 EXPECT_EQ(-2, columnWidthUTF8("\344\270")); in TEST()
47 EXPECT_EQ(-2, columnWidthUTF8("\344\270\033")); in TEST()
48 EXPECT_EQ(-2, columnWidthUTF8("\344\270\300")); in TEST()
49 EXPECT_EQ(-2, columnWidthUTF8("\377\366\355")); in TEST()
51 EXPECT_EQ(-2, columnWidthUTF8("qwer\344")); in TEST()
52 EXPECT_EQ(-2, columnWidthUTF8("qwer\344\270")); in TEST()
53 EXPECT_EQ(-2, columnWidthUTF8("qwer\344\270\033")); in TEST()
54 EXPECT_EQ(-2, columnWidthUTF8("qwer\344\270\300")); in TEST()
55 EXPECT_EQ(-2, columnWidthUTF8("qwer\377\366\355")); in TEST()
59 EXPECT_EQ(-2, columnWidthUTF8("\370\200\200\200\200")); // U+200000 in TEST()
60 EXPECT_EQ(-2, columnWidthUTF8("\374\200\200\200\200\200")); // U+4000000 in TEST()