aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/client/modeltest.cpp8
-rwxr-xr-xtests/client/script_modeltest.py2
2 files changed, 9 insertions, 1 deletions
diff --git a/tests/client/modeltest.cpp b/tests/client/modeltest.cpp
index 1c2eeca..93677db 100644
--- a/tests/client/modeltest.cpp
+++ b/tests/client/modeltest.cpp
@@ -212,7 +212,13 @@ private Q_SLOTS:
QCOMPARE(v.type(), QVariant::Map);
QCOMPARE(v.toMap(), map);
- }
+
+ // Utf8
+ v = extra["utf8"];
+ QCOMPARE(v.type(), QVariant::String);
+ QCOMPARE(v.toString(), QString("dança"));
+
+ }
/*
* Test if model is destroyed without crash
diff --git a/tests/client/script_modeltest.py b/tests/client/script_modeltest.py
index 84a0d9c..72c294c 100755
--- a/tests/client/script_modeltest.py
+++ b/tests/client/script_modeltest.py
@@ -1,4 +1,5 @@
#!/usr/bin/env python3
+# -*- coding: utf-8 -*-
import time
from gi.repository import GLib
@@ -21,6 +22,7 @@ al.appendItem("Menu0", "Menu0Act", None, None, {'x-boolean' : GLib.Variant('b',
'x-uint64' : GLib.Variant('t', 42),
'x-double' : GLib.Variant('d', 42.42),
'x-string' : GLib.Variant('s', '42'),
+ 'x-utf8' : GLib.Variant('s', 'dança'),
'x-map' : GLib.Variant('a{sv}', pmap),
})
al.appendItem("Menu1", "Menu1Act")