summaryrefslogtreecommitdiffstats
path: root/tests/testsupport.py
diff options
context:
space:
mode:
authorJohan Dahlin <jdahlin@src.gnome.org>2004-07-10 16:56:36 +0000
committerJohan Dahlin <jdahlin@src.gnome.org>2004-07-10 16:56:36 +0000
commit8238d9cc0fce600328f50efa139db1f575058ae8 (patch)
tree945ced41b87cdff3fd2ac2cb34b84d96f54ae2db /tests/testsupport.py
parentd47520065b91d4f2b9f7e4a53faf008adc780113 (diff)
downloadpygobject-8238d9cc0fce600328f50efa139db1f575058ae8.tar.gz
pygobject-8238d9cc0fce600328f50efa139db1f575058ae8.tar.xz
pygobject-8238d9cc0fce600328f50efa139db1f575058ae8.zip
New script to run all tests in one take
* tests/runtests.py: New script to run all tests in one take * tests/Makefile.am: autotoolify * tests/signal.py: New simple test taken from examples/gobject/signal.py
Diffstat (limited to 'tests/testsupport.py')
-rw-r--r--tests/testsupport.py30
1 files changed, 0 insertions, 30 deletions
diff --git a/tests/testsupport.py b/tests/testsupport.py
deleted file mode 100644
index bc23975..0000000
--- a/tests/testsupport.py
+++ /dev/null
@@ -1,30 +0,0 @@
-# -*- Mode: Python; py-indent-offset: 4 -*-
-
-import sys
-import os
-import unittest
-import __main__
-
-# Insert parent directory into path
-def insert_pygtk_python_paths():
- try:
- filename = __file__
- except:
- filename = sys.argv[0]
- this_dir = os.path.dirname(os.path.abspath(filename))
- parent_dir = os.path.dirname(this_dir)
- sys.path.insert(0, parent_dir)
-
-insert_pygtk_python_paths()
-
-def run_all_tests(mods = [__main__]):
- runner = unittest.TextTestRunner()
- for mod in mods:
- for name in dir(mod):
- val = getattr(mod, name)
- try:
- if issubclass(val, unittest.TestCase):
- suite = unittest.makeSuite(val, 'test')
- runner.run(suite)
- except TypeError:
- pass