From ca7a8cf05893ee127cbcaa9e9e85d0d13bc1b7ee Mon Sep 17 00:00:00 2001 From: Rob Austein Date: Thu, 16 Jun 2016 13:43:15 -0400 Subject: Completely farbled most of the super() incantations, sigh. --- unit_tests.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/unit_tests.py b/unit_tests.py index 6634b7b..4b02a35 100644 --- a/unit_tests.py +++ b/unit_tests.py @@ -121,12 +121,13 @@ class TimedTestCase(unittest.TestCase): """ def setUp(self): + super(TimedTestCase, self).setUp() self.startTime = datetime.datetime.now() def tearDown(self): self.endTime = datetime.datetime.now() log("runtime {} seconds ... ".format(self.endTime - self.startTime)) - + super(TimedTestCase, self).tearDown() class TestInit(TimedTestCase): """ @@ -152,7 +153,7 @@ class TestInit(TimedTestCase): p11.C_Initialize(CKF_OS_LOCKING_OK, mdb.create, mdb.destroy, mdb.lock, mdb.unlock) def tearDown(self): - super(TestKeys, self).setUp() + super(TestInit, self).tearDown() p11.C_Finalize() @@ -170,7 +171,7 @@ class TestDevice(TimedTestCase): p11.C_Finalize() def tearDown(self): - super(TestKeys, self).setUp() + super(TestDevice, self).tearDown() p11.C_CloseAllSessions(args.slot) def test_getSlots(self): @@ -260,7 +261,7 @@ class TestKeys(TimedTestCase): super(TestKeys, self).setUp() def tearDown(self): - super(TestKeys, self).setUp() + super(TestKeys, self).tearDown() for handle in p11.FindObjects(self.session): p11.C_DestroyObject(self.session, handle) p11.C_CloseAllSessions(args.slot) -- cgit v1.2.3