summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2012-04-20 16:52:45 +0200
committerQt by Nokia <qt-info@nokia.com>2012-04-20 22:23:23 +0200
commit369863efefb3b63859b9de48915f5f3da65be76a (patch)
treea93721dd764c825487705637199ec2adb830a654 /tests/auto/corelib
parentfffc900f78a191970c4eebced9c1af016a9ea6f4 (diff)
Don't push unnecessary data to a data stream for QVariant()
Adjust the test because we don't read past the end anymore. Task-number: QTBUG-25108 Change-Id: I8243f1d5ae79d1256aab2cb1132598a716a7eeeb Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Diffstat (limited to 'tests/auto/corelib')
-rw-r--r--tests/auto/corelib/kernel/qvariant/tst_qvariant.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/corelib/kernel/qvariant/tst_qvariant.cpp b/tests/auto/corelib/kernel/qvariant/tst_qvariant.cpp
index 91b56e4e9b..dca2ee36a6 100644
--- a/tests/auto/corelib/kernel/qvariant/tst_qvariant.cpp
+++ b/tests/auto/corelib/kernel/qvariant/tst_qvariant.cpp
@@ -2901,13 +2901,13 @@ void tst_QVariant::loadUnknownUserType()
void tst_QVariant::loadBrokenUserType()
{
- char data[] = {0, 0, 0, 127, 0, 112 };
+ char data[] = {0, 0, 0, 127, 0 };
QByteArray ba(data, sizeof(data));
QDataStream ds(&ba, QIODevice::ReadOnly);
QVariant var;
var.load(ds);
- QCOMPARE(ds.status(), QDataStream::ReadPastEnd);
+ QCOMPARE(ds.status(), QDataStream::Ok);
}
void tst_QVariant::invalidDate() const