[test] Avoid usage of lgc.testlib TestCase in unittest_cwconfig.py
authorDenis Laxalde <denis.laxalde@logilab.fr>
Tue, 12 Jul 2016 15:30:07 +0200
changeset 11448 f79c6894381f
parent 11447 ced4de539d66
child 11449 ea5299828d68
[test] Avoid usage of lgc.testlib TestCase in unittest_cwconfig.py
cubicweb/test/unittest_cwconfig.py
--- a/cubicweb/test/unittest_cwconfig.py	Mon Jul 18 13:59:47 2016 +0200
+++ b/cubicweb/test/unittest_cwconfig.py	Tue Jul 12 15:30:07 2016 +0200
@@ -21,13 +21,13 @@
 import os
 import tempfile
 from os.path import dirname, join, abspath
+import unittest
 
 from logilab.common.modutils import cleanup_sys_modules
-from logilab.common.testlib import (TestCase, unittest_main,
-                                    with_tempdir)
+from logilab.common.testlib import with_tempdir
 from logilab.common.changelog import Version
 
-from cubicweb.devtools import ApptestConfiguration
+from cubicweb.devtools import ApptestConfiguration, testlib
 from cubicweb.cwconfig import _find_prefix
 
 def unabsolutize(path):
@@ -40,7 +40,8 @@
 CUSTOM_CUBES_DIR = abspath(join(dirname(__file__), 'data', 'cubes'))
 
 
-class CubicWebConfigurationTC(TestCase):
+class CubicWebConfigurationTC(testlib.BaseTestCase):
+
     def setUp(self):
         cleanup_sys_modules([CUSTOM_CUBES_DIR, ApptestConfiguration.CUBES_DIR])
         self.config = ApptestConfiguration('data', __file__)
@@ -132,7 +133,7 @@
         self.assertEqual(file.__path__, [join(CUSTOM_CUBES_DIR, 'file')])
 
 
-class FindPrefixTC(TestCase):
+class FindPrefixTC(unittest.TestCase):
     def make_dirs(self, *args):
         path = join(tempfile.tempdir, *args)
         if not os.path.exists(path):
@@ -231,4 +232,4 @@
 
 
 if __name__ == '__main__':
-    unittest_main()
+    unittest.main()