/django/contrib/gis/gdal/tests/__init__.py

https://code.google.com/p/mango-py/ · Python · 25 lines · 16 code · 4 blank · 5 comment · 0 complexity · c0060a111494132952dafc05426a7dfb MD5 · raw file

  1. """
  2. Module for executing all of the GDAL tests. None
  3. of these tests require the use of the database.
  4. """
  5. from django.utils.unittest import TestSuite, TextTestRunner
  6. # Importing the GDAL test modules.
  7. import test_driver, test_ds, test_envelope, test_geom, test_srs
  8. test_suites = [test_driver.suite(),
  9. test_ds.suite(),
  10. test_envelope.suite(),
  11. test_geom.suite(),
  12. test_srs.suite(),
  13. ]
  14. def suite():
  15. "Builds a test suite for the GDAL tests."
  16. s = TestSuite()
  17. map(s.addTest, test_suites)
  18. return s
  19. def run(verbosity=1):
  20. "Runs the GDAL tests."
  21. TextTestRunner(verbosity=verbosity).run(suite())