diff options
author | Michael Brasser <michael.brasser@nokia.com> | 2012-06-22 09:23:26 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-06-22 06:54:59 +0200 |
commit | 55faad4873a9409bb1b33a10da7329d13a95aff9 (patch) | |
tree | b08f5b801079e49ddc9d6a5839eeb14a1e238a0f /tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp | |
parent | 033bf75d99c281d4a133fada297b7b141a0af555 (diff) |
Handle enum values of -1 correctly.
This was already handled correctly most places; now the
remaining cases (using an enum in ListModel, and assigning
an enum to an integer property) should also work correctly.
Task-number: QTBUG-21679
Change-Id: Ibff13f0b94da94b18e2e3bae4aa6ba44e0fa944b
Reviewed-by: Chris Adams <christopher.adams@nokia.com>
Diffstat (limited to 'tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp')
-rw-r--r-- | tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp b/tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp index d344758147..c429ffaa4b 100644 --- a/tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp +++ b/tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp @@ -983,6 +983,7 @@ void tst_qqmlecmascript::enums() QCOMPARE(object->property("f").toInt(), 3); QCOMPARE(object->property("h").toInt(), 2); QCOMPARE(object->property("i").toInt(), 3); + QCOMPARE(object->property("j").toInt(), -1); // count of change signals QCOMPARE(object->property("ac").toInt(), 0); @@ -993,6 +994,7 @@ void tst_qqmlecmascript::enums() QCOMPARE(object->property("fc").toInt(), 0); QCOMPARE(object->property("hc").toInt(), 1); // namespace -> binding QCOMPARE(object->property("ic").toInt(), 1); // namespace -> binding + QCOMPARE(object->property("jc").toInt(), 0); delete object; } |