aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2016-10-12 20:49:36 +0200
committerLiang Qi <liang.qi@qt.io>2016-10-12 20:49:45 +0200
commitb4cdfc4a12d2b9ebc79fe17a2f1aff67bd940d71 (patch)
treee7841ee2695a3ef180e186d2df971c8fc207d0f9 /tests
parent650b5db06b057abe2db40fb8d56223e17ba8c06a (diff)
parentaf002b8df9b084fd7f26e9eead9844aab36bdc4d (diff)
Merge remote-tracking branch 'origin/5.6' into 5.7
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/qml/qjsengine/tst_qjsengine.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/auto/qml/qjsengine/tst_qjsengine.cpp b/tests/auto/qml/qjsengine/tst_qjsengine.cpp
index 13bfa16581..63fefbe9f1 100644
--- a/tests/auto/qml/qjsengine/tst_qjsengine.cpp
+++ b/tests/auto/qml/qjsengine/tst_qjsengine.cpp
@@ -190,6 +190,7 @@ private slots:
void v4FunctionWithoutQML();
void withNoContext();
+ void holeInPropertyData();
signals:
void testSignal();
@@ -3862,6 +3863,19 @@ void tst_QJSEngine::withNoContext()
engine.evaluate("with (noContext) true");
}
+void tst_QJSEngine::holeInPropertyData()
+{
+ QJSEngine engine;
+ QJSValue ok = engine.evaluate(
+ "var o = {};\n"
+ "o.bar = 0xcccccccc;\n"
+ "o.foo = 0x55555555;\n"
+ "Object.defineProperty(o, 'bar', { get: function() { return 0xffffffff }});\n"
+ "o.bar === 0xffffffff && o.foo === 0x55555555;");
+ QVERIFY(ok.isBool());
+ QVERIFY(ok.toBool());
+}
+
QTEST_MAIN(tst_QJSEngine)
#include "tst_qjsengine.moc"