Lines Matching refs:utf8

75 static std::wstring UTF8ToWide(const std::string& utf8) {  in UTF8ToWide()  argument
77 EXPECT_TRUE(UTF8ToWide(utf8, &utf16)); in UTF8ToWide()
82 std::string utf8; in WideToUTF8() local
83 EXPECT_TRUE(WideToUTF8(utf16, &utf8)); in WideToUTF8()
84 return utf8; in WideToUTF8()
123 std::ostringstream utf8; in TEST() local
124 utf8 << WideToUTF8(kConvertRoundtripCases[i]); in TEST()
126 wide << UTF8ToWide(utf8.str()); in TEST()
143 const char* utf8; in TEST() member
174 const bool success = UTF8ToWide(convert_cases[i].utf8, in TEST()
175 strlen(convert_cases[i].utf8), in TEST()
208 const char* utf8; in TEST() member
251 std::string expected(convert_cases[i].utf8); in TEST()
264 const char* utf8; in TEST() member
287 std::string expected(convert_cases[i].utf8); in TEST()
347 static std::wstring SysUTF8ToWide(const std::string& utf8) { in SysUTF8ToWide() argument
348 return UTF8ToWide(utf8); in SysUTF8ToWide()
417 std::string utf8 = "c:\\mypath\\myfile.txt"; in TEST() local
420 EXPECT_TRUE(UTF8PathToWindowsLongPath(utf8.c_str(), &wide)); in TEST()
426 std::string utf8 = "c:\\mypath"; in TEST() local
427 while (utf8.length() < 300 /* MAX_PATH is 260 */) { in TEST()
428 utf8 += "\\mypathsegment"; in TEST()
432 EXPECT_TRUE(UTF8PathToWindowsLongPath(utf8.c_str(), &wide)); in TEST()
439 std::string utf8 = "c:/mypath"; in TEST() local
440 while (utf8.length() < 300 /* MAX_PATH is 260 */) { in TEST()
441 utf8 += "/mypathsegment"; in TEST()
445 EXPECT_TRUE(UTF8PathToWindowsLongPath(utf8.c_str(), &wide)); in TEST()
451 namespace utf8 { namespace
457 std::string utf8 = td.path; in TEST() local
458 while (utf8.length() < 300 /* MAX_PATH is 260 */) { in TEST()
459 utf8 += "\\mypathsegment"; in TEST()
460 EXPECT_EQ(0, mkdir(utf8.c_str(), 0)); in TEST()
464 utf8 += "\\test-file.bin"; in TEST()
467 android::base::unique_fd fd(open(utf8.c_str(), flags, mode)); in TEST()
475 FILE* file = fopen(utf8.c_str(), "rb"); in TEST()
483 EXPECT_EQ(0, unlink(utf8.c_str())); in TEST()