summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/scion/scion.pro1
-rw-r--r--tests/auto/scion/tst_scion.cpp10
2 files changed, 6 insertions, 5 deletions
diff --git a/tests/auto/scion/scion.pro b/tests/auto/scion/scion.pro
index 14e825f..6b4accf 100644
--- a/tests/auto/scion/scion.pro
+++ b/tests/auto/scion/scion.pro
@@ -6,6 +6,7 @@ TARGET = tst_scion
TEMPLATE = app
RESOURCES = $$OUT_PWD/scion.qrc
+DEFINES += QT_NO_CAST_FROM_ASCII QT_NO_CAST_TO_ASCII
SOURCES += \
tst_scion.cpp
diff --git a/tests/auto/scion/tst_scion.cpp b/tests/auto/scion/tst_scion.cpp
index 40da0a6..30ada94 100644
--- a/tests/auto/scion/tst_scion.cpp
+++ b/tests/auto/scion/tst_scion.cpp
@@ -305,7 +305,7 @@ static bool playEvent(QScxmlStateMachine *stateMachine, const QJsonObject &event
Q_ASSERT(eventDescription.contains(QLatin1String("event")));
auto event = eventDescription.value(QLatin1String("event")).toObject();
- auto eventName = event.value(QLatin1String("name")).toString().toUtf8();
+ auto eventName = event.value(QLatin1String("name")).toString();
Q_ASSERT(!eventName.isEmpty());
QScxmlEvent::EventType type = QScxmlEvent::ExternalEvent;
if (event.contains(QLatin1String("type"))) {
@@ -324,18 +324,18 @@ static bool playEvent(QScxmlStateMachine *stateMachine, const QJsonObject &event
if (event.contains(QLatin1String("data"))) {
data = event.value(QLatin1String("data")).toVariant();
}
- QByteArray sendid;
+ QString sendid;
if (event.contains(QLatin1String("sendid")))
- sendid = event.value(QLatin1String("sendid")).toString().toUtf8();
+ sendid = event.value(QLatin1String("sendid")).toString();
QString origin;
if (event.contains(QLatin1String("origin")))
origin = event.value(QLatin1String("origin")).toString();
QString origintype;
if (event.contains(QLatin1String("origintype")))
origintype = event.value(QLatin1String("origintype")).toString();
- QByteArray invokeid;
+ QString invokeid;
if (event.contains(QLatin1String("invokeid")))
- invokeid = event.value(QLatin1String("invokeid")).toString().toUtf8();
+ invokeid = event.value(QLatin1String("invokeid")).toString();
QScxmlEvent *e = new QScxmlEvent;
e->setName(eventName);
e->setEventType(type);