diff options
author | Michael Brasser <michael.brasser@nokia.com> | 2012-02-15 09:29:54 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-15 02:07:38 +0100 |
commit | 0ae106b5d9b23ed35a27ee409827dd623a4a1b50 (patch) | |
tree | 668968c9d9357b14bce9e92ac5a09a8c47f8e58f /tests/auto/declarative/v4/tst_v4.cpp | |
parent | be47ec24cf51b1d4b7692e35345704bac9897a2e (diff) |
Add string comparison test for v4.
Change-Id: Ibd98608ca0c757afdde1db18877a5a92cdeb24ba
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
Diffstat (limited to 'tests/auto/declarative/v4/tst_v4.cpp')
-rw-r--r-- | tests/auto/declarative/v4/tst_v4.cpp | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/tests/auto/declarative/v4/tst_v4.cpp b/tests/auto/declarative/v4/tst_v4.cpp index fb6f8776e0..8a550a5c2d 100644 --- a/tests/auto/declarative/v4/tst_v4.cpp +++ b/tests/auto/declarative/v4/tst_v4.cpp @@ -70,6 +70,7 @@ private slots: void subscriptionsInConditionalExpressions(); void qtbug_21883(); void qtbug_22816(); + void stringComparison(); private: QDeclarativeEngine engine; @@ -272,6 +273,37 @@ void tst_v4::qtbug_22816() delete o; } +void tst_v4::stringComparison() +{ + QDeclarativeComponent component(&engine, testFileUrl("stringComparison.qml")); + + QObject *o = component.create(); + QVERIFY(o != 0); + QCOMPARE(o->property("test1").toBool(), true); + QCOMPARE(o->property("test2").toBool(), true); + QCOMPARE(o->property("test3").toBool(), true); + QCOMPARE(o->property("test4").toBool(), true); + QCOMPARE(o->property("test5").toBool(), true); + QCOMPARE(o->property("test6").toBool(), true); + QCOMPARE(o->property("test7").toBool(), true); + QCOMPARE(o->property("test8").toBool(), true); + QCOMPARE(o->property("test9").toBool(), true); + QCOMPARE(o->property("test10").toBool(), true); + QCOMPARE(o->property("test11").toBool(), true); + QCOMPARE(o->property("test12").toBool(), true); + QCOMPARE(o->property("test13").toBool(), true); + QCOMPARE(o->property("test14").toBool(), true); + QCOMPARE(o->property("test15").toBool(), true); + QCOMPARE(o->property("test16").toBool(), true); + QCOMPARE(o->property("test17").toBool(), true); + QCOMPARE(o->property("test18").toBool(), true); + QCOMPARE(o->property("test19").toBool(), true); + QCOMPARE(o->property("test20").toBool(), true); + QCOMPARE(o->property("test21").toBool(), true); + QCOMPARE(o->property("test22").toBool(), true); + delete o; +} + QTEST_MAIN(tst_v4) #include "tst_v4.moc" |