diff options
author | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2013-10-29 13:38:57 +0000 |
---|---|---|
committer | Simon McVittie <simon.mcvittie@collabora.co.uk> | 2013-10-31 14:45:47 +0000 |
commit | 041c785bff016a22188cef1c2a88b9f7a6888e63 (patch) | |
tree | de3e1582b12c2c7b270c7540d70ba522369e0ec0 /tests/twisted | |
parent | f57ad64d19ff9002e0820678b3aca472a02c2270 (diff) |
Default accounts backend: store attributes in a properly typed form
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=54875
Reviewed-by: Guillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Diffstat (limited to 'tests/twisted')
-rw-r--r-- | tests/twisted/account-storage/default-keyring-storage.py | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/tests/twisted/account-storage/default-keyring-storage.py b/tests/twisted/account-storage/default-keyring-storage.py index 58ef1089..6ed673e3 100644 --- a/tests/twisted/account-storage/default-keyring-storage.py +++ b/tests/twisted/account-storage/default-keyring-storage.py @@ -118,11 +118,10 @@ def test(q, bus, mc): 'Icon')) assertEquals("'Joe Bloggs'", account_store('get', 'variant-file', 'Nickname')) - # For now, everything is a keyfile-escaped string - assertEquals("'true'", account_store('get', 'variant-file', + assertEquals('true', account_store('get', 'variant-file', 'ConnectAutomatically')) - assertEquals("'4;xa;never online;'", account_store('get', 'variant-file', - 'AutomaticPresence')) + assertEquals("(uint32 4, 'xa', 'never online')", + account_store('get', 'variant-file', 'AutomaticPresence')) assertEquals("keyfile-escaped 'dontdivert@example.com'", account_store('get', 'variant-file', 'param-account')) assertEquals("keyfile-escaped 'secrecy'", @@ -166,13 +165,11 @@ def test(q, bus, mc): # This is deliberately a lower-priority location open(low_prio_variant_file_name, 'w').write( - # For now, everything is a keyfile-escaped string, so AutomaticPresence - # is weird """{ 'manager': <'fakecm'>, 'protocol': <'fakeprotocol'>, 'DisplayName': <'New and improved account'>, -'AutomaticPresence': <'2;available;;'>, +'AutomaticPresence': <(uint32 2, 'available', '')>, 'KeyFileParameters': <{ 'account': 'dontdivert@example.com', 'password': 'password_in_variant_file' @@ -186,7 +183,7 @@ def test(q, bus, mc): 'manager': <'fakecm'>, 'protocol': <'fakeprotocol'>, 'DisplayName': <'Visible'>, -'AutomaticPresence': <'2;available;;'>, +'AutomaticPresence': <(uint32 2, 'available', '')>, 'KeyFileParameters': <{'account': 'dontdivert@example.com', 'password': 'password_in_variant_file'}> } @@ -198,7 +195,7 @@ def test(q, bus, mc): 'protocol': <'fakeprotocol'>, 'DisplayName': <'Hidden'>, 'Nickname': <'Hidden'>, -'AutomaticPresence': <'2;available;;'>, +'AutomaticPresence': <(uint32 2, 'available', '')>, 'KeyFileParameters': <{'account': 'dontdivert@example.com', 'password': 'password_in_variant_file'}> } @@ -211,7 +208,7 @@ def test(q, bus, mc): 'w').write("""{ 'manager': <'fakecm'>, 'protocol': <'fakeprotocol'>, -'AutomaticPresence': <'2;available;;'>, +'AutomaticPresence': <(uint32 2, 'available', '')>, 'KeyFileParameters': <{'account': 'dontdivert@example.com', 'password': 'password_in_variant_file'}> } |