telepathy-gabble: test-multift: clean up a bit

Will Thompson wjt at kemper.freedesktop.org
Thu Dec 6 04:04:37 PST 2012


Module: telepathy-gabble
Branch: master
Commit: b735dc9c1320b9a6c206a0856758c60c130428a8
URL:    http://cgit.freedesktop.org/telepathy/telepathy-gabble/commit/?id=b735dc9c1320b9a6c206a0856758c60c130428a8

Author: Will Thompson <will.thompson at collabora.co.uk>
Date:   Thu Dec  6 12:04:17 2012 +0000

test-multift: clean up a bit

---

 tests/twisted/jingle-share/test-multift.py |   12 +-----------
 1 files changed, 1 insertions(+), 11 deletions(-)

diff --git a/tests/twisted/jingle-share/test-multift.py b/tests/twisted/jingle-share/test-multift.py
index acd6c57..d318e42 100644
--- a/tests/twisted/jingle-share/test-multift.py
+++ b/tests/twisted/jingle-share/test-multift.py
@@ -1,22 +1,13 @@
 import dbus
 
-from twisted.words.xish import xpath
 from twisted.words.protocols.jabber.client import IQ
 
 from servicetest import assertEquals, assertSameSets, EventPattern
 from gabbletest import exec_test, sync_stream
 import constants as cs
 
-from caps_helper import compute_caps_hash, \
-    text_fixed_properties, text_allowed_properties, \
-    stream_tube_fixed_properties, stream_tube_allowed_properties, \
-    dbus_tube_fixed_properties, dbus_tube_allowed_properties, \
-    ft_fixed_properties, ft_allowed_properties
-
 from jingleshareutils import test_ft_caps_from_contact
 
-import ns
-
 from config import JINGLE_FILE_TRANSFER_ENABLED
 
 if not JINGLE_FILE_TRANSFER_ENABLED:
@@ -131,8 +122,7 @@ def test(q, bus, conn, stream):
 
     event = q.expect('stream-iq', to=contact,
                      iq_type='set', query_name='session')
-    stanza = event.stanza
-    session_node = xpath.queryForNodes('/iq/session', event.stanza)[0]
+    session_node = event.query
     assert session_node.attributes['type'] == 'transport-accept'
 
     # Close all but one of the channels, and make sure Gabble doesn't cancel



More information about the telepathy-commits mailing list