summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/utils.py16
1 files changed, 15 insertions, 1 deletions
diff --git a/tests/utils.py b/tests/utils.py
index 25452d5c..5e42082c 100644
--- a/tests/utils.py
+++ b/tests/utils.py
@@ -1,7 +1,21 @@
# vim: tabstop=4 shiftwidth=4 softtabstop=4
+import time
+
+import mox
import unittest
class TestCase(unittest.TestCase):
- pass
+
+ def setUp(self):
+ super(TestCase, self).setUp()
+ self.mox = mox.Mox()
+ self._original_time = time.time
+ time.time = lambda: 1234
+
+ def tearDown(self):
+ time.time = self._original_time
+ super(TestCase, self).tearDown()
+ self.mox.UnsetStubs()
+ self.mox.VerifyAll()