From 759e40b66beded76c4b21d7aab452033e845422b Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Mon, 23 Sep 2013 16:06:05 +0100 Subject: [PATCH 15/16] Remove unused function close_all_groups() This was the last reference to Handle_Type_Contact_List, Handle_Type_Contact_Group or Chan.T.ContactList outside constants.py. --- tests/twisted/hazetest.py | 11 ----------- tests/twisted/roster/groups.py | 2 +- tests/twisted/roster/publish.py | 2 +- tests/twisted/roster/subscribe.py | 2 +- 4 files changed, 3 insertions(+), 14 deletions(-) diff --git a/tests/twisted/hazetest.py b/tests/twisted/hazetest.py index 7df7f3d..e03c58c 100644 --- a/tests/twisted/hazetest.py +++ b/tests/twisted/hazetest.py @@ -74,14 +74,3 @@ def exec_test(fun, params=None, protocol=EmptyRosterXmppXmlStream, timeout=None, exec_test_deferred, fun, params, protocol, timeout, authenticator, num_instances, do_connect, make_haze_connection, expect_kinda_connected) reactor.run() - -def close_all_groups(q, bus, conn, stream): - channels = conn.Properties.Get(cs.CONN_IFACE_REQUESTS, 'Channels') - for path, props in channels: - if props.get(cs.CHANNEL_TYPE) != cs.CHANNEL_TYPE_CONTACT_LIST: - continue - if props.get(cs.TARGET_HANDLE_TYPE) != cs.HT_GROUP: - continue - wrap_channel(bus.get_object(conn.bus_name, path), - cs.CHANNEL_TYPE_CONTACT_LIST).Close() - diff --git a/tests/twisted/roster/groups.py b/tests/twisted/roster/groups.py index 3e2dfee..0ded827 100644 --- a/tests/twisted/roster/groups.py +++ b/tests/twisted/roster/groups.py @@ -9,7 +9,7 @@ from twisted.words.xish import domish, xpath from servicetest import (EventPattern, wrap_channel, assertLength, assertEquals, call_async, sync_dbus, assertContains, assertSameSets) -from hazetest import acknowledge_iq, exec_test, sync_stream, close_all_groups +from hazetest import acknowledge_iq, exec_test, sync_stream import constants as cs import ns diff --git a/tests/twisted/roster/publish.py b/tests/twisted/roster/publish.py index 3b97cbb..df88ce2 100644 --- a/tests/twisted/roster/publish.py +++ b/tests/twisted/roster/publish.py @@ -9,7 +9,7 @@ from twisted.words.xish import domish from servicetest import (EventPattern, wrap_channel, assertLength, assertEquals, call_async, sync_dbus, assertSameSets) -from hazetest import acknowledge_iq, exec_test, sync_stream, close_all_groups +from hazetest import acknowledge_iq, exec_test, sync_stream import constants as cs import ns diff --git a/tests/twisted/roster/subscribe.py b/tests/twisted/roster/subscribe.py index b736d0d..b39f86e 100644 --- a/tests/twisted/roster/subscribe.py +++ b/tests/twisted/roster/subscribe.py @@ -8,7 +8,7 @@ from twisted.words.xish import domish from servicetest import (EventPattern, wrap_channel, assertLength, assertEquals, call_async, sync_dbus) -from hazetest import acknowledge_iq, exec_test, sync_stream, close_all_groups +from hazetest import acknowledge_iq, exec_test, sync_stream import constants as cs import ns -- 1.8.4.rc3