From 8f0584a2042946f1bbe41b48a57c3a824ffd443b Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Thu, 19 Oct 2006 12:48:59 +0000 Subject: Allow listening for events even when a command is sent --- test/apitest | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'test') diff --git a/test/apitest b/test/apitest index 83988896..6d16e7ac 100755 --- a/test/apitest +++ b/test/apitest @@ -399,7 +399,8 @@ class Tester: self.dbus_mgr_sig_setup() self.dbus_dev_sig_setup() print 'Listening for events...' - elif self.cmd in mgr_cmds: + + if self.cmd in mgr_cmds: try: self.dbus_mgr_setup() except dbus.DBusException, e: @@ -413,7 +414,7 @@ class Tester: print 'Failed to setup device interface: %s' % e sys.exit(1) self.call_dev_dbus_func() - else: + elif not self.listen: print 'Unknown command: %s' % self.cmd self.usage() sys.exit(1) -- cgit