diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2011-11-08 12:19:47 +0000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-11-09 11:31:10 +0100 |
commit | 0c5f9185502f3f81265a044955bd13040c2446db (patch) | |
tree | c5da2abe25e23fa9fe7768abae2ecd0a3626f688 /tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp | |
parent | da8d1689ef3d4efc769465d195840c5058b38e81 (diff) |
Return a string from resolvedUrl() to match 4.x behavior
Task-number: QTBUG-20960
Change-Id: I9ae99ada5c9bbe7498df24908c6acd202ca73a15
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Diffstat (limited to 'tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp')
-rw-r--r-- | tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp b/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp index b4ac2dfc66..b6cebf40ec 100644 --- a/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp +++ b/tests/auto/declarative/qdeclarativeqt/tst_qdeclarativeqt.cpp @@ -89,6 +89,7 @@ private slots: void atob(); void fontFamilies(); void quit(); + void resolvedUrl(); private: QDeclarativeEngine engine; @@ -727,6 +728,19 @@ void tst_qdeclarativeqt::quit() delete object; } +void tst_qdeclarativeqt::resolvedUrl() +{ + QDeclarativeComponent component(&engine, TEST_FILE("resolvedUrl.qml")); + + QObject *object = component.create(); + QVERIFY(object != 0); + + QCOMPARE(object->property("result").toString(), component.url().toString()); + QCOMPARE(object->property("isString").toBool(), true); + + delete object; +} + QTEST_MAIN(tst_qdeclarativeqt) #include "tst_qdeclarativeqt.moc" |