summaryrefslogtreecommitdiffstats
path: root/test/deactivate-context
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2010-10-21 21:44:51 +0200
committerMarcel Holtmann <marcel@holtmann.org>2010-10-21 21:46:32 +0200
commitfcc064e55c5da5a1dd3816d4add7c0143d622663 (patch)
treef59ba541b76d354181cb9b3bf93d84e9e6834f60 /test/deactivate-context
parent56d46ae16b36e756c9aa032029d30ef6dbf4fe4e (diff)
downloadofono-fcc064e55c5da5a1dd3816d4add7c0143d622663.tar.bz2
test: Add option to also enable other than the first context
Diffstat (limited to 'test/deactivate-context')
-rwxr-xr-xtest/deactivate-context5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/deactivate-context b/test/deactivate-context
index 04d4bc81..e3754c2e 100755
--- a/test/deactivate-context
+++ b/test/deactivate-context
@@ -23,7 +23,10 @@ for path, properties in modems:
print "No context available"
sys.exit(1)
- path = contexts[0][0]
+ if len(sys.argv) > 1:
+ path = contexts[int(sys.argv[1])][0]
+ else:
+ path = contexts[0][0]
context = dbus.Interface(bus.get_object('org.ofono', path),
'org.ofono.ConnectionContext')