summaryrefslogtreecommitdiffstats
path: root/tests/auto/other/lancelot
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/other/lancelot')
-rw-r--r--tests/auto/other/lancelot/paintcommands.cpp3
-rw-r--r--tests/auto/other/lancelot/scripts/paths.qps2
-rw-r--r--tests/auto/other/lancelot/tst_lancelot.cpp2
3 files changed, 3 insertions, 4 deletions
diff --git a/tests/auto/other/lancelot/paintcommands.cpp b/tests/auto/other/lancelot/paintcommands.cpp
index d810e6e41a..969db62acb 100644
--- a/tests/auto/other/lancelot/paintcommands.cpp
+++ b/tests/auto/other/lancelot/paintcommands.cpp
@@ -848,8 +848,7 @@ void PaintCommands::command_import(QRegExp re)
QFileInfo fileinfo(*file);
m_commands[m_currentCommandIndex] = QString("# import file (%1) start").arg(fileinfo.fileName());
- QTextStream textFile(file);
- QString rawContent = textFile.readAll();
+ QString rawContent = QString::fromUtf8(file->readAll());
QStringList importedData = rawContent.split('\n', QString::SkipEmptyParts);
importedData.append(QString("# import file (%1) end ---").arg(fileinfo.fileName()));
insertAt(m_currentCommandIndex, importedData);
diff --git a/tests/auto/other/lancelot/scripts/paths.qps b/tests/auto/other/lancelot/scripts/paths.qps
index 083026ee17..555390de45 100644
--- a/tests/auto/other/lancelot/scripts/paths.qps
+++ b/tests/auto/other/lancelot/scripts/paths.qps
@@ -10,7 +10,7 @@ path_lineTo star 0 20
path_lineTo star 80 100
setFont "times" 50
-path_addText text 0 50 "ABCD, 1234, abcd, #¤%&"
+path_addText text 0 50 "ABCD, 1234, abcd, #¤%&"
path_addRect rectncircle 0 0 75 75
path_addEllipse rectncircle 25 25 75 75
diff --git a/tests/auto/other/lancelot/tst_lancelot.cpp b/tests/auto/other/lancelot/tst_lancelot.cpp
index 05623f9f5c..4bb0bae243 100644
--- a/tests/auto/other/lancelot/tst_lancelot.cpp
+++ b/tests/auto/other/lancelot/tst_lancelot.cpp
@@ -125,7 +125,7 @@ void tst_Lancelot::initTestCase()
QFile file(scriptsDir + fileName);
file.open(QFile::ReadOnly);
QByteArray cont = file.readAll();
- scripts.insert(fileName, QString::fromLatin1(cont).split(QLatin1Char('\n'), QString::SkipEmptyParts));
+ scripts.insert(fileName, QString::fromUtf8(cont).split(QLatin1Char('\n'), QString::SkipEmptyParts));
it->itemName = fileName;
it->itemChecksum = qChecksum(cont.constData(), cont.size());
it++;