summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp
diff options
context:
space:
mode:
authorAaron Kennedy <aaron.kennedy@nokia.com>2010-04-08 04:27:04 (GMT)
committerAaron Kennedy <aaron.kennedy@nokia.com>2010-04-08 04:27:56 (GMT)
commita8247ce85808614f6ec921a37bae9fb0d447252b (patch)
treed5b280d784c239ebea328a6b6b5d23946c0c26e9 /tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp
parent224189f1531bc9e2e25b9ea72038e240bd3550a9 (diff)
downloadQt-a8247ce85808614f6ec921a37bae9fb0d447252b.zip
Qt-a8247ce85808614f6ec921a37bae9fb0d447252b.tar.gz
Qt-a8247ce85808614f6ec921a37bae9fb0d447252b.tar.bz2
Autotest for 76f5e9e7d1eea8d688d5459b7b7b2bfa3f9057ed
Diffstat (limited to 'tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp')
-rw-r--r--tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp b/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp
index 77dd4b8..8e73afa 100644
--- a/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp
+++ b/tests/auto/declarative/qdeclarativeecmascript/tst_qdeclarativeecmascript.cpp
@@ -543,11 +543,20 @@ void tst_qdeclarativeecmascript::extensionObjects()
QVERIFY(object != 0);
QCOMPARE(object->baseProperty(), 13);
QCOMPARE(object->coreProperty(), 9);
-
object->setProperty("extendedProperty", QVariant(11));
object->setProperty("baseExtendedProperty", QVariant(92));
QCOMPARE(object->coreProperty(), 11);
QCOMPARE(object->baseProperty(), 92);
+
+ MyExtendedObject *nested = qobject_cast<MyExtendedObject*>(qvariant_cast<QObject *>(object->property("nested")));
+ QVERIFY(nested);
+ QCOMPARE(nested->baseProperty(), 13);
+ QCOMPARE(nested->coreProperty(), 9);
+ nested->setProperty("extendedProperty", QVariant(11));
+ nested->setProperty("baseExtendedProperty", QVariant(92));
+ QCOMPARE(nested->coreProperty(), 11);
+ QCOMPARE(nested->baseProperty(), 92);
+
}
void tst_qdeclarativeecmascript::attachedProperties()