diff options
author | Olivier Tilloy <olivier.tilloy@canonical.com> | 2012-10-30 13:01:18 +0100 |
---|---|---|
committer | Olivier Tilloy <olivier.tilloy@canonical.com> | 2012-10-30 13:01:18 +0100 |
commit | 0ad7c832a92d7e3fd763d6c281338243e684865f (patch) | |
tree | 2b5756922a0d7cfc98de5c55de3aeb6f0ee3823e /tests/client | |
parent | 209c95ea443041146229336379e66e659d72edae (diff) | |
parent | 035b6086485dcd3b42abc5d1fab2b155ccd16027 (diff) | |
download | qmenumodel-0ad7c832a92d7e3fd763d6c281338243e684865f.tar.gz qmenumodel-0ad7c832a92d7e3fd763d6c281338243e684865f.tar.bz2 qmenumodel-0ad7c832a92d7e3fd763d6c281338243e684865f.zip |
Merge the latest changes from trunk.
Diffstat (limited to 'tests/client')
-rw-r--r-- | tests/client/modeltest.cpp | 8 | ||||
-rwxr-xr-x | tests/client/script_modeltest.py | 2 |
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") |