aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/qml/qjsengine/tst_qjsengine.cpp8
-rw-r--r--tests/auto/qml/qqmlengine/tst_qqmlengine.cpp2
2 files changed, 9 insertions, 1 deletions
diff --git a/tests/auto/qml/qjsengine/tst_qjsengine.cpp b/tests/auto/qml/qjsengine/tst_qjsengine.cpp
index 39086d75ac..726f8636b6 100644
--- a/tests/auto/qml/qjsengine/tst_qjsengine.cpp
+++ b/tests/auto/qml/qjsengine/tst_qjsengine.cpp
@@ -134,6 +134,7 @@ private slots:
void reentrancy_Array();
void reentrancy_objectCreation();
void jsIncDecNonObjectProperty();
+ void JSONparse();
void qRegExpInport_data();
void qRegExpInport();
@@ -2500,6 +2501,13 @@ void tst_QJSEngine::jsIncDecNonObjectProperty()
}
}
+void tst_QJSEngine::JSONparse()
+{
+ QJSEngine eng;
+ QJSValue ret = eng.evaluate("var json=\"{\\\"1\\\": null}\"; JSON.parse(json);");
+ QVERIFY(ret.isObject());
+}
+
static QRegExp minimal(QRegExp r) { r.setMinimal(true); return r; }
void tst_QJSEngine::qRegExpInport_data()
diff --git a/tests/auto/qml/qqmlengine/tst_qqmlengine.cpp b/tests/auto/qml/qqmlengine/tst_qqmlengine.cpp
index 382bfe4b73..004514d39c 100644
--- a/tests/auto/qml/qqmlengine/tst_qqmlengine.cpp
+++ b/tests/auto/qml/qqmlengine/tst_qqmlengine.cpp
@@ -54,7 +54,7 @@
#include <QQmlExpression>
#include <QQmlIncubationController>
#include <private/qqmlengine_p.h>
-#include <private/qqmlabstracturlinterceptor_p.h>
+#include <QQmlAbstractUrlInterceptor>
class tst_qqmlengine : public QQmlDataTest
{