summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2010-05-20 04:23:07 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2010-05-20 04:23:07 (GMT)
commit5b3937ce27d04ce240662521321dfdc3e1a8373b (patch)
tree25b02b34a9a92781378c3eba1db7f78a7908938a /tests/auto/declarative
parentcae5ae70dab4272e5b7313ea101ce32eb6c22240 (diff)
downloadQt-5b3937ce27d04ce240662521321dfdc3e1a8373b.zip
Qt-5b3937ce27d04ce240662521321dfdc3e1a8373b.tar.gz
Qt-5b3937ce27d04ce240662521321dfdc3e1a8373b.tar.bz2
Ensure valuetype enums can be assigned from JS
QTBUG-10830
Diffstat (limited to 'tests/auto/declarative')
-rw-r--r--tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp b/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
index 95b9baa..53fd68c 100644
--- a/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
+++ b/tests/auto/declarative/qdeclarativevaluetypes/tst_qdeclarativevaluetypes.cpp
@@ -838,6 +838,14 @@ void tst_qdeclarativevaluetypes::enums()
QVERIFY(object->font().capitalization() == QFont::AllUppercase);
delete object;
}
+
+ {
+ QDeclarativeComponent component(&engine, TEST_FILE("enums.5.qml"));
+ MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create());
+ QVERIFY(object != 0);
+ QVERIFY(object->font().capitalization() == QFont::AllUppercase);
+ delete object;
+ }
}
// Tests switching between "conflicting" bindings (eg. a binding on the core