summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@theqtcompany.com>2015-06-27 13:58:32 +0200
committerSimon Hausmann <simon.hausmann@theqtcompany.com>2015-06-27 13:04:47 +0000
commita3e0fe474c20eb526af9668c5cc97cf7055c77fa (patch)
tree91d9d307d31ad2c0caac6d4a571d63d9d909f400 /tests
parent2420ae95b2e00f5b4aa605fa968152873e91b505 (diff)
downloadqtwebsockets-a3e0fe474c20eb526af9668c5cc97cf7055c77fa.tar.gz
Fix incorrectly encoded data tag
Properly encode the provided sequence in UTF-8, so that the XML output of testlib is correctly encoded. Otherwise parsing the XML output in an automated manner breaks. Change-Id: Ibf0d5d6d067f4daeb7d2efd242d64b5f472d7b83 Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/dataprocessor/tst_dataprocessor.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/auto/dataprocessor/tst_dataprocessor.cpp b/tests/auto/dataprocessor/tst_dataprocessor.cpp
index 660d8eb..c1dd9a1 100644
--- a/tests/auto/dataprocessor/tst_dataprocessor.cpp
+++ b/tests/auto/dataprocessor/tst_dataprocessor.cpp
@@ -329,7 +329,7 @@ void tst_DataProcessor::goodTextFrame_data()
//error C2308: concatenating mismatched strings
QTest::newRow((QStringLiteral("Text frame containing Hello-") +
QStringLiteral("\xC2\xB5\x40\xC3\x9F\xC3\xB6\xC3\xA4\xC3\xBC\xC3\xA0") +
- QStringLiteral("\xC3\xA1-UTF-8!!")).toLatin1().constData())
+ QStringLiteral("\xC3\xA1-UTF-8!!")).toUtf8().constData())
<< QByteArray::fromHex("48656c6c6f2dc2b540c39fc3b6c3a4c3bcc3a0c3a12d5554462d382121")
<< 22;
}