Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Use Python 2.7's unittest discovery.

  • Loading branch information...
commit aa687fb4ffd00455963ef39eec9296fa775dd275 1 parent 64afc2e
@sfllaw sfllaw authored
Showing with 12 additions and 11 deletions.
  1. +5 −3 test.py
  2. +7 −8 tests/__init__.py
View
8 test.py
@@ -1,8 +1,10 @@
#!/usr/bin/env python
+# -*- coding: utf-8 -*-
-import unittest
+from __future__ import (absolute_import, division, print_function,
+ unicode_literals)
-from tests import *
+import unittest
if __name__ == '__main__':
- unittest.main()
+ unittest.main(module='tests')
View
15 tests/__init__.py
@@ -3,11 +3,10 @@
from __future__ import (absolute_import, division, print_function,
unicode_literals)
-from .test_gdal import *
-from .test_helpers import *
-from .test_mbtiles import *
-from .test_renderers import *
-from .test_scripts import *
-from .test_storages import *
-from .test_types import *
-from .test_vips import *
+import os
+
+
+def load_tests(loader, tests, pattern):
+ discovered = loader.discover(start_dir=os.path.dirname(__file__))
+ tests.addTests(tests=discovered)
+ return tests
Please sign in to comment.
Something went wrong with that request. Please try again.