diff options
author | Duncan McGreggor <duncan@ubuntu.com> | 2011-03-14 22:31:31 -0600 |
---|---|---|
committer | Duncan McGreggor <duncan@ubuntu.com> | 2011-03-14 22:31:31 -0600 |
commit | a818534b4c9967faf27e8b8d1548e6bded60dd3a (patch) | |
tree | 5a0a7f1481bca3121cc5a5d8a136f6d094aba11c /python | |
parent | 0c8f095bac6d4d8987cb0d32b46b38696d1d204d (diff) |
Added debugging info to trace the issue with devices not being destoryed after
a unit test is run.
Diffstat (limited to 'python')
-rw-r--r-- | python/evemu/testing.py | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/python/evemu/testing.py b/python/evemu/testing.py index 50536e8..611dca2 100644 --- a/python/evemu/testing.py +++ b/python/evemu/testing.py @@ -44,10 +44,18 @@ class Non26BaseTestCase(unittest.TestCase): safe_repr(container)) self.fail(_formatMessage(msg, standardMsg)) + # XXX debugging + def setUp(self): + super(Non26BaseTestCase, self).setUp() + print util.get_all_device_numbers() + class BaseTestCase(unittest.TestCase): def setUp(self): + super(BaseTestCase, self).setUp() + # XXX debugging + print "\nsetUp: ", util.get_all_device_numbers() library = find_library(const.LIB) if not library: if os.path.exists(const.DEFAULT_LIB): @@ -61,6 +69,12 @@ class BaseTestCase(unittest.TestCase): basedir = util.get_top_directory() self.data_dir = os.path.join(basedir, "..", "..", "data") + # XXX debugging + def tearDown(self): + super(BaseTestCase, self).tearDown() + print "tearDown: ", util.get_all_device_numbers(), "\n" + + def get_device_file(self): return os.path.join(self.data_dir, "ntrig-dell-xt2.prop") |