Test only fix - Bug 477577 - Encoding errors compiling TestAUSReadStrings.cpp
This commit is contained in:
Родитель
c35a71ee6d
Коммит
4ba559da49
|
@ -97,19 +97,28 @@ int NS_main(int argc, NS_tchar **argv)
|
|||
}
|
||||
|
||||
*(++slash) = '\0';
|
||||
|
||||
// Test success when the ini file exists with both Title and InfoText in the
|
||||
// Strings section and test values for Title and InfoText.
|
||||
NS_tsnprintf(inifile, sizeof(inifile), NS_T("%sTestAUSReadStrings1.ini"), argv[0]);
|
||||
retval = ReadStrings(inifile, &testStrings);
|
||||
if (retval == OK) {
|
||||
if (strcmp(testStrings.title, "Title Test - 测试 測試 Δοκιμή テスト Испытание") != 0) {
|
||||
if (strcmp(testStrings.title, "Title Test - \xE6\xB5\x8B\xE8\xAF\x95 " \
|
||||
"\xE6\xB8\xAC\xE8\xA9\xA6 " \
|
||||
"\xCE\x94\xCE\xBF\xCE\xBA\xCE\xB9\xCE\xBC\xCE\xAE " \
|
||||
"\xE3\x83\x86\xE3\x82\xB9\xE3\x83\x88 " \
|
||||
"\xD0\x98\xD1\x81\xD0\xBF\xD1\x8B\xD1\x82\xD0" \
|
||||
"\xB0\xD0\xBD\xD0\xB8\xD0\xB5") != 0) {
|
||||
rv = 21;
|
||||
printf("%s | %s Title ini value incorrect | Test 1\n",
|
||||
UNEXPECTED_FAIL_PREFIX, TEST_NAME);
|
||||
}
|
||||
|
||||
if (strcmp(testStrings.info, "InfoText Test - 测试 測試 Δοκιμή テスト Испытание…") != 0) {
|
||||
if (strcmp(testStrings.info, "InfoText Test - \xE6\xB5\x8B\xE8\xAF\x95 " \
|
||||
"\xE6\xB8\xAC\xE8\xA9\xA6 " \
|
||||
"\xCE\x94\xCE\xBF\xCE\xBA\xCE\xB9\xCE\xBC\xCE\xAE " \
|
||||
"\xE3\x83\x86\xE3\x82\xB9\xE3\x83\x88 " \
|
||||
"\xD0\x98\xD1\x81\xD0\xBF\xD1\x8B\xD1\x82\xD0\xB0" \
|
||||
"\xD0\xBD\xD0\xB8\xD0\xB5\xE2\x80\xA6") != 0) {
|
||||
rv = 22;
|
||||
printf("%s | %s InfoText ini value incorrect | Test 1\n",
|
||||
UNEXPECTED_FAIL_PREFIX, TEST_NAME);
|
||||
|
@ -126,13 +135,23 @@ int NS_main(int argc, NS_tchar **argv)
|
|||
NS_tsnprintf(inifile, sizeof(inifile), NS_T("%sTestAUSReadStrings2.ini"), argv[0]);
|
||||
retval = ReadStrings(inifile, &testStrings);
|
||||
if (retval == OK) {
|
||||
if (strcmp(testStrings.title, "Title Test - Испытание Δοκιμή テスト 測試 测试") != 0) {
|
||||
if (strcmp(testStrings.title, "Title Test - \xD0\x98\xD1\x81\xD0\xBF\xD1\x8B" \
|
||||
"\xD1\x82\xD0\xB0\xD0\xBD\xD0\xB8\xD0\xB5 " \
|
||||
"\xCE\x94\xCE\xBF\xCE\xBA\xCE\xB9\xCE\xBC\xCE\xAE " \
|
||||
"\xE3\x83\x86\xE3\x82\xB9\xE3\x83\x88 " \
|
||||
"\xE6\xB8\xAC\xE8\xA9\xA6 " \
|
||||
"\xE6\xB5\x8B\xE8\xAF\x95") != 0) {
|
||||
rv = 24;
|
||||
printf("%s | %s Title ini value incorrect | Test 2\n",
|
||||
UNEXPECTED_FAIL_PREFIX, TEST_NAME);
|
||||
}
|
||||
|
||||
if (strcmp(testStrings.info, "Info Test - Испытание Δοκιμή テスト 測試 测试…") != 0) {
|
||||
if (strcmp(testStrings.info, "Info Test - \xD0\x98\xD1\x81\xD0\xBF\xD1\x8B" \
|
||||
"\xD1\x82\xD0\xB0\xD0\xBD\xD0\xB8\xD0\xB5 " \
|
||||
"\xCE\x94\xCE\xBF\xCE\xBA\xCE\xB9\xCE\xBC\xCE\xAE " \
|
||||
"\xE3\x83\x86\xE3\x82\xB9\xE3\x83\x88 " \
|
||||
"\xE6\xB8\xAC\xE8\xA9\xA6 " \
|
||||
"\xE6\xB5\x8B\xE8\xAF\x95\xE2\x80\xA6") != 0) {
|
||||
rv = 25;
|
||||
printf("%s | %s Info ini value incorrect | Test 2\n",
|
||||
UNEXPECTED_FAIL_PREFIX, TEST_NAME);
|
||||
|
|
Загрузка…
Ссылка в новой задаче