[pitivi: 31/65] Make the same initial checks as the application when the tests package is initialized.
- From: Thibault Saunier <tsaunier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi: 31/65] Make the same initial checks as the application when the tests package is initialized.
- Date: Mon, 4 Jul 2011 01:21:50 +0000 (UTC)
commit 957955d010bfc8d436eb67b0b4052c6a70ecd70f
Author: Alex BÄluÈ <alexandru balut gmail com>
Date: Thu Jun 9 12:22:27 2011 +0200
Make the same initial checks as the application when the tests package is initialized.
tests/__init__.py | 10 +++++++---
tests/test_timeline.py | 1 -
2 files changed, 7 insertions(+), 4 deletions(-)
---
diff --git a/tests/__init__.py b/tests/__init__.py
index 7778160..ad60903 100644
--- a/tests/__init__.py
+++ b/tests/__init__.py
@@ -1,3 +1,7 @@
-import pygst
-pygst.require("0.10")
-import gst
+from pitivi.check import initial_checks
+
+
+missing_deps = initial_checks()
+if missing_deps:
+ message, detail = missing_deps
+ raise Exception("%s\n%s" % (message, detail))
diff --git a/tests/test_timeline.py b/tests/test_timeline.py
index 56429af..ccd48d6 100644
--- a/tests/test_timeline.py
+++ b/tests/test_timeline.py
@@ -20,7 +20,6 @@
# Boston, MA 02110-1301, USA.
import pygst
-pygst.require("0.10")
import gst
from tests.common import FakeSourceFactory, FakeEffectFactory
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]