diff options
author | Thiago Macieira <thiago.macieira@nokia.com> | 2010-02-13 15:24:56 (GMT) |
---|---|---|
committer | Thiago Macieira <thiago.macieira@nokia.com> | 2010-02-13 15:24:56 (GMT) |
commit | dcb2678f39345b66c5303e74c156654a8d13fe83 (patch) | |
tree | d2c7f2c9de464b1908316b94c07cc8ece831ad00 /tests/auto/declarative/qmlqt/data/createComponent.qml | |
parent | 03a55630cfccf7f6ed01d865c541e07afb25c96e (diff) | |
parent | 6944a72cd26a5e3611ebd305ec665bc4c0fcee12 (diff) | |
download | Qt-dcb2678f39345b66c5303e74c156654a8d13fe83.zip Qt-dcb2678f39345b66c5303e74c156654a8d13fe83.tar.gz Qt-dcb2678f39345b66c5303e74c156654a8d13fe83.tar.bz2 |
Merge remote branch 'origin/master' into qt-master-from-4.6
Conflicts:
tests/auto/qlineedit/tst_qlineedit.cpp
tests/benchmarks/benchmarks.pro
Diffstat (limited to 'tests/auto/declarative/qmlqt/data/createComponent.qml')
-rw-r--r-- | tests/auto/declarative/qmlqt/data/createComponent.qml | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/auto/declarative/qmlqt/data/createComponent.qml b/tests/auto/declarative/qmlqt/data/createComponent.qml new file mode 100644 index 0000000..d9b70ec --- /dev/null +++ b/tests/auto/declarative/qmlqt/data/createComponent.qml @@ -0,0 +1,23 @@ +import Qt 4.6 + +QtObject { + property bool incorrectArgCount1: false + property bool incorrectArgCount2: false + property bool emptyArg: false + + property string relativeUrl + property string absoluteUrl + + Component.onCompleted: { + // Test that using incorrect argument count returns a null object + incorrectArgCount1 = (createComponent() == null); + incorrectArgCount2 = (createComponent("main.qml", 10) == null); + emptyArg = (createComponent("") == null); + + var r = createComponent("createComponentData.qml"); + relativeUrl = r.url; + + var a = createComponent("http://www.example.com/test.qml"); + absoluteUrl = a.url; + } +} |