[pitivi] dogtail tests: Provide a way to shut down the app "properly"
- From: Jean-FranÃois Fortin Tam <jfft src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] dogtail tests: Provide a way to shut down the app "properly"
- Date: Wed, 25 Jul 2012 11:56:33 +0000 (UTC)
commit 9c217302a42d29725b7bd4ee3e987662b25454bf
Author: Jean-FranÃois Fortin Tam <nekohayo gmail com>
Date: Sun Jul 22 12:54:03 2012 -0400
dogtail tests: Provide a way to shut down the app "properly"
tests/dogtail_scripts/test_base.py | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/tests/dogtail_scripts/test_base.py b/tests/dogtail_scripts/test_base.py
index 5c1e5c4..305d33a 100644
--- a/tests/dogtail_scripts/test_base.py
+++ b/tests/dogtail_scripts/test_base.py
@@ -30,9 +30,13 @@ class BaseDogTail(unittest.TestCase):
except AttributeError:
self.unlink = []
- def tearDown(self, clean=True):
- # Try to kill pitivi before leaving test
- os.system("kill -9 %i" % self.pid)
+ def tearDown(self, clean=True, kill=True):
+ if kill:
+ os.system("kill -9 %i" % self.pid)
+ else:
+ proj_menu = self.menubar.menu("Project")
+ proj_menu.click()
+ proj_menu.child("Quit").click()
if clean:
for filename in self.unlink:
try:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]