import os
import logging
import time
-import unittest
+from unittest2 import TestCase
from htsworkflow.util.queuecommands import QueueCommands
-class testQueueCommands(unittest.TestCase):
+class testQueueCommands(TestCase):
def setUp(self):
logging.basicConfig(level=logging.DEBUG,
format='%(asctime)s %(name)-8s %(message)s')
-
-
def test_unlimited_run_slow(self):
"""
Run everything at once
self.failUnless( end > 3.9 and end < 4.1,
"took %s seconds, expected ~4" % (end,))
-def suite():
- return unittest.makeSuite(testQueueCommands, 'test')
-
-if __name__ == "__main__":
- unittest.main(defaultTest='suite')
-
+def suite():
+ from unittest2 import TestSuite, defaultTestLoader
+ suite = TestSuite()
+ suite.addTests(defaultTestLoader.loadTestsFromTestCase(testQueueCommands))
+ return suite
+if __name__ == "__main__":
+ from unittest2 import main
+ main(defaultTest="suite")