summaryrefslogtreecommitdiffstats
path: root/test/hangup-active
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2010-09-29 08:08:09 +0900
committerMarcel Holtmann <marcel@holtmann.org>2010-09-29 08:08:09 +0900
commitba2fd65b5e18eccdbb67352a4c9500aa291de81c (patch)
treebe521bd784d04c467469b8fd66e7964596c4b161 /test/hangup-active
parent5269a2f9be76bb230afd70ba8d8dd1fe80b9e4ad (diff)
downloadofono-ba2fd65b5e18eccdbb67352a4c9500aa291de81c.tar.bz2
test: Add script for hanging up active call
Diffstat (limited to 'test/hangup-active')
-rwxr-xr-xtest/hangup-active23
1 files changed, 23 insertions, 0 deletions
diff --git a/test/hangup-active b/test/hangup-active
new file mode 100755
index 00000000..52dd2c6a
--- /dev/null
+++ b/test/hangup-active
@@ -0,0 +1,23 @@
+#!/usr/bin/python
+
+import sys
+import dbus
+
+bus = dbus.SystemBus()
+
+manager = dbus.Interface(bus.get_object('org.ofono', '/'),
+ 'org.ofono.Manager')
+
+modems = manager.GetModems()
+path = modems[0][0]
+
+manager = dbus.Interface(bus.get_object('org.ofono', path),
+ 'org.ofono.VoiceCallManager')
+
+calls = manager.GetCalls()
+path = calls[0][0]
+
+call = dbus.Interface(bus.get_object('org.ofono', path),
+ 'org.ofono.VoiceCall')
+
+call.Hangup()