aboutsummaryrefslogtreecommitdiff
path: root/tests/client/convertertest.cpp
diff options
context:
space:
mode:
authorRenato Araujo Oliveira Filho <renato.filho@canonical.com>2012-10-17 15:10:49 +0000
committerTarmac <>2012-10-17 15:10:49 +0000
commitd46ee24446b49d8ef00f9f0aef44ee863966f245 (patch)
tree6c13049fc74b0c44d2bbe28dfd1dc212dad1970c /tests/client/convertertest.cpp
parentced307a448aeed3a20d1a1e4bdcbf4dcbe4b1e46 (diff)
parentcdd910c7a326af6d87acc6df1c90016c8e30cbc7 (diff)
downloadqmenumodel-d46ee24446b49d8ef00f9f0aef44ee863966f245.tar.gz
qmenumodel-d46ee24446b49d8ef00f9f0aef44ee863966f245.tar.bz2
qmenumodel-d46ee24446b49d8ef00f9f0aef44ee863966f245.zip
Implemented conversion for QVariantMap;
Created unit test for QVariantMap conversion;. Approved by Olivier Tilloy, PS Jenkins bot.
Diffstat (limited to 'tests/client/convertertest.cpp')
-rw-r--r--tests/client/convertertest.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/client/convertertest.cpp b/tests/client/convertertest.cpp
index 72b6a87..633ecf1 100644
--- a/tests/client/convertertest.cpp
+++ b/tests/client/convertertest.cpp
@@ -35,7 +35,7 @@ private:
bool compare(const QVariant &qv, const GVariantType *type)
{
bool result;
- GVariant *gv = Converter::toGVariant(qv);
+ GVariant *gv = Converter::toGVariant(qv);
result = g_variant_type_equal(g_variant_get_type(gv), type);
if (!result) {
qWarning() << "types are different: QVariant:" << qv.typeName()
@@ -48,7 +48,6 @@ private:
private Q_SLOTS:
-
/*
* Test converter QVariant to GVariant
*/
@@ -86,6 +85,9 @@ private Q_SLOTS:
// ByteArray
QVERIFY(compare(QVariant(QByteArray("42")), G_VARIANT_TYPE_BYTESTRING));
+
+ // Map
+ QVERIFY(compare(QVariantMap(), G_VARIANT_TYPE_VARDICT));
}
};