summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Arve Sæther <jan-arve.saether@qt.io>2018-06-28 10:25:22 +0200
committerJan Arve Sæther <jan-arve.saether@qt.io>2018-06-28 10:30:25 +0000
commit1d2294735536c53fca8e56ed4b262c4bca6b4d29 (patch)
tree3f2264366fbc64c1ba7c2ac781d9049770abd82e
parent9acfa7d281efceec38ef8e8bdd03376993fd2594 (diff)
downloadqtscript-1d2294735536c53fca8e56ed4b262c4bca6b4d29.tar.gz
Fix xml output to have valid UTF-8
Some datatags had characters outside the ASCII range. (This is discouraged). And when dumping the datatag to xml output we dumped the binary content of the data tag without encoding it from latin1 to utf-8. This meant that all characters in the range 0x80-0xff produced invalid utf-8 sequences. The solution is to encode the data tag as UTF-8. Change-Id: Iaaecc992b756836845bfb98429f20f1fb5e2b291 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
-rw-r--r--tests/auto/qscriptjstestsuite/tst_qscriptjstestsuite.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/qscriptjstestsuite/tst_qscriptjstestsuite.cpp b/tests/auto/qscriptjstestsuite/tst_qscriptjstestsuite.cpp
index 102229f..73a1575 100644
--- a/tests/auto/qscriptjstestsuite/tst_qscriptjstestsuite.cpp
+++ b/tests/auto/qscriptjstestsuite/tst_qscriptjstestsuite.cpp
@@ -266,7 +266,7 @@ void tst_QScriptJSTestSuite::runTestFunction(int testIndex)
actual.toString(), expect.toString(),
relpath, lineNumber);
- QTest::newRow(description.toLatin1()) << rec;
+ QTest::newRow(description.toUtf8()) << rec;
}
}
if (!hasData)