summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp')
-rw-r--r--tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp b/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
index 87a60e30e5..a21ffc634d 100644
--- a/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
+++ b/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
@@ -96,6 +96,7 @@ private slots:
void returnValues();
void varAssignment();
void bindingsSpliceCorrectly();
+ void qtbug_33625();
private:
QDeclarativeEngine engine;
@@ -1012,6 +1013,19 @@ void tst_qdeclarativevaluetypes::bindingsSpliceCorrectly()
}
}
+//qreal as float should not limit int to single precision.
+void tst_qdeclarativevaluetypes::qtbug_33625()
+{
+ QDeclarativeComponent component(&engine, TEST_FILE("qtbug-33625.qml"));
+ QObject *object = component.create();
+ QVERIFY(object != 0);
+
+ QCOMPARE(object->property("intint").toInt(), 16777237);
+ QCOMPARE(object->property("stringint").toInt(), 16777237);
+
+ delete object;
+}
+
QTEST_MAIN(tst_qdeclarativevaluetypes)
#include "tst_qdeclarativevaluetypes.moc"