summaryrefslogtreecommitdiffstats
path: root/tests/auto/qscriptvalue
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-07-29 08:52:24 (GMT)
committerKent Hansen <khansen@trolltech.com>2009-07-29 08:53:23 (GMT)
commite5262a0c29c743f2afd4ba249e8adff984c1ca83 (patch)
tree1cfd16f32658ea45a586edf08efa01071ec2b587 /tests/auto/qscriptvalue
parenta7cc30b30df53d6a70208c25f6c12a9f229b3ea6 (diff)
downloadQt-e5262a0c29c743f2afd4ba249e8adff984c1ca83.zip
Qt-e5262a0c29c743f2afd4ba249e8adff984c1ca83.tar.gz
Qt-e5262a0c29c743f2afd4ba249e8adff984c1ca83.tar.bz2
add more extensive tests for scopechain functionality
Diffstat (limited to 'tests/auto/qscriptvalue')
-rw-r--r--tests/auto/qscriptvalue/tst_qscriptvalue.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/qscriptvalue/tst_qscriptvalue.cpp b/tests/auto/qscriptvalue/tst_qscriptvalue.cpp
index ff2df7a..7939b4c 100644
--- a/tests/auto/qscriptvalue/tst_qscriptvalue.cpp
+++ b/tests/auto/qscriptvalue/tst_qscriptvalue.cpp
@@ -2148,6 +2148,14 @@ void tst_QScriptValue::getSetScope()
QCOMPARE(object2.scope().strictlyEquals(object), true);
+ object.setProperty("foo", 123);
+ QVERIFY(!object2.property("foo").isValid());
+ {
+ QScriptValue ret = object2.property("foo", QScriptValue::ResolveScope);
+ QVERIFY(ret.isNumber());
+ QCOMPARE(ret.toInt32(), 123);
+ }
+
QScriptValue inv;
inv.setScope(object);
QCOMPARE(inv.scope().isValid(), false);