summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/qdeclarativecontext
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/declarative/qdeclarativecontext')
-rw-r--r--tests/auto/declarative/qdeclarativecontext/tst_qdeclarativecontext.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/auto/declarative/qdeclarativecontext/tst_qdeclarativecontext.cpp b/tests/auto/declarative/qdeclarativecontext/tst_qdeclarativecontext.cpp
index be20ba1..ae62363 100644
--- a/tests/auto/declarative/qdeclarativecontext/tst_qdeclarativecontext.cpp
+++ b/tests/auto/declarative/qdeclarativecontext/tst_qdeclarativecontext.cpp
@@ -228,7 +228,7 @@ private:
#define TEST_CONTEXT_PROPERTY(ctxt, name, value) \
{ \
QDeclarativeComponent component(&engine); \
- component.setData("import Qt 4.6; QtObject { property var test: " #name " }", QUrl()); \
+ component.setData("import Qt 4.6; QtObject { property variant test: " #name " }", QUrl()); \
\
QObject *obj = component.create(ctxt); \
\
@@ -278,7 +278,7 @@ void tst_qdeclarativecontext::setContextProperty()
// Changes in context properties
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { property var test: a }", QUrl());
+ component.setData("import Qt 4.6; QtObject { property variant test: a }", QUrl());
QObject *obj = component.create(&ctxt2);
@@ -290,7 +290,7 @@ void tst_qdeclarativecontext::setContextProperty()
}
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { property var test: b }", QUrl());
+ component.setData("import Qt 4.6; QtObject { property variant test: b }", QUrl());
QObject *obj = component.create(&ctxt2);
@@ -304,7 +304,7 @@ void tst_qdeclarativecontext::setContextProperty()
}
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { property var test: e.a }", QUrl());
+ component.setData("import Qt 4.6; QtObject { property variant test: e.a }", QUrl());
QObject *obj = component.create(&ctxt2);
@@ -318,7 +318,7 @@ void tst_qdeclarativecontext::setContextProperty()
// New context properties
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { property var test: a }", QUrl());
+ component.setData("import Qt 4.6; QtObject { property variant test: a }", QUrl());
QObject *obj = component.create(&ctxt2);
@@ -332,7 +332,7 @@ void tst_qdeclarativecontext::setContextProperty()
// Setting an object-variant context property
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { id: root; property int a: 10; property int test: ctxtProp.a; property var obj: root; }", QUrl());
+ component.setData("import Qt 4.6; QtObject { id: root; property int a: 10; property int test: ctxtProp.a; property variant obj: root; }", QUrl());
QDeclarativeContext ctxt(engine.rootContext());
ctxt.setContextProperty("ctxtProp", QVariant());
@@ -380,7 +380,7 @@ void tst_qdeclarativecontext::setContextObject()
// Changes in context properties
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { property var test: a }", QUrl());
+ component.setData("import Qt 4.6; QtObject { property variant test: a }", QUrl());
QObject *obj = component.create(&ctxt);
@@ -412,7 +412,7 @@ void tst_qdeclarativecontext::destruction()
void tst_qdeclarativecontext::idAsContextProperty()
{
QDeclarativeComponent component(&engine);
- component.setData("import Qt 4.6; QtObject { property var a; a: QtObject { id: myObject } }", QUrl());
+ component.setData("import Qt 4.6; QtObject { property variant a; a: QtObject { id: myObject } }", QUrl());
QObject *obj = component.create();
QVERIFY(obj);