Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@localhost.localdomain>2006-10-02 12:28:22 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2006-10-02 12:28:22 (GMT)
commit4958c43b33f3a02982b58f612f2ba46b069d12bf (patch)
treec2dbf115143d07fe5be7ba03f2f93d2a44139044 /tests
parentc6aa561fe9bdbc69d9e85bc57461305b365eb464 (diff)
Add window manager test
Diffstat (limited to 'tests')
-rwxr-xr-xtests/test-window-manager.py28
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/test-window-manager.py b/tests/test-window-manager.py
new file mode 100755
index 0000000..413a9dd
--- /dev/null
+++ b/tests/test-window-manager.py
@@ -0,0 +1,28 @@
+#!/usr/bin/python
+import pygtk
+pygtk.require('2.0')
+
+from sugar.session.UITestSession import UITestSession
+
+session = UITestSession()
+session.start()
+
+import gtk
+
+def _show_dialog(window):
+ dialog = gtk.Dialog(title='No Unviewed Media',
+ parent=window, flags=gtk.DIALOG_MODAL,
+ buttons=(gtk.STOCK_OK, gtk.RESPONSE_ACCEPT))
+ label = gtk.Label('There is no unviewed media to download.')
+ dialog.vbox.pack_start(label, True, True, 0)
+ label.show()
+ response = dialog.run()
+ dialog.hide()
+ del dialog
+
+window = gtk.Window()
+window.show()
+
+_show_dialog(window)
+
+gtk.main()