diff options
author | Mitch Curtis <mitch.curtis@theqtcompany.com> | 2015-01-22 10:38:34 +0100 |
---|---|---|
committer | Mitch Curtis <mitch.curtis@digia.com> | 2015-02-11 09:22:25 +0000 |
commit | fe1726fd7d33a5e1bda863ca6000bc3b9806b1aa (patch) | |
tree | 20c33cd76fa1ac1c82f3afb2017052e8273af80c /tests/auto/corelib/json | |
parent | 51ce5b482997f76b8890876b07337b29609728e5 (diff) |
Document and further test that QJsonObject::keys() is sorted.
Change-Id: I6b145c1240cce85ad3fea6fb90ddbed629487f83
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'tests/auto/corelib/json')
-rw-r--r-- | tests/auto/corelib/json/tst_qtjson.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/corelib/json/tst_qtjson.cpp b/tests/auto/corelib/json/tst_qtjson.cpp index 56a5a28c50..b6cfc39bb9 100644 --- a/tests/auto/corelib/json/tst_qtjson.cpp +++ b/tests/auto/corelib/json/tst_qtjson.cpp @@ -1051,6 +1051,8 @@ void tst_QtJson::keySorting() QCOMPARE(it.key(), QLatin1String("A")); ++it; QCOMPARE(it.key(), QLatin1String("B")); + + QCOMPARE(o.keys(), QStringList() << QLatin1String("A") << QLatin1String("B")); } void tst_QtJson::undefinedValues() |