diff options
author | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2010-05-19 15:33:43 +0200 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2010-05-19 15:33:43 +0200 |
commit | 506f164532b3a2fc5b8b232b42414e7bc79c17b4 (patch) | |
tree | c9fed3e2d108e7f4c0340d316f0f2711dfa2553d | |
parent | c758ce6dd21a56641b78b36137274a13d8270488 (diff) | |
download | telepathy-mission-control-506f164532b3a2fc5b8b232b42414e7bc79c17b4.tar.gz |
account-manager/presence.py: GetInterfaces can be called twice
-rw-r--r-- | test/twisted/account-manager/presence.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/test/twisted/account-manager/presence.py b/test/twisted/account-manager/presence.py index f84c60e9..aa8c0d2c 100644 --- a/test/twisted/account-manager/presence.py +++ b/test/twisted/account-manager/presence.py @@ -80,9 +80,14 @@ def test(q, bus, mc): e.args[0].get('CurrentPresence') == presence), ]) - # The events before Connect must happen in this order - assert log == ['GetInterfaces', 'Get(Statuses)[1]', 'SetPresence[1]', - 'Get(Statuses)[2]', 'SetPresence[2]'], log + # The events before Connect must happen in this order. GetInterfaces() may + # be called once or 2 times + if len(log) == 5: + assert log == ['GetInterfaces', 'Get(Statuses)[1]', 'SetPresence[1]', + 'Get(Statuses)[2]', 'SetPresence[2]'], log + else: + assert log == ['GetInterfaces', 'GetInterfaces', 'Get(Statuses)[1]', 'SetPresence[1]', + 'Get(Statuses)[2]', 'SetPresence[2]'], log # Change requested presence after going online presence = dbus.Struct((dbus.UInt32(cs.PRESENCE_TYPE_AWAY), 'away', |