Django

Code

Changeset 6240

Show
Ignore:
Timestamp:
09/14/07 17:46:41 (1 year ago)
Author:
jbronn
Message:

gis: Fixed #5437 with patch from rcoup.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/branches/gis/django/contrib/gis/tests/__init__.py

    r6237 r6240  
    11from copy import copy 
    22from unittest import TestSuite, TextTestRunner 
     3import sys 
    34 
    45# Tests that do not require setting up and tearing down a spatial database. 
    5 test_suite_names = ['test_gdal_driver', 
    6                     'test_gdal_ds', 
    7                     'test_gdal_geom', 
    8                     'test_gdal_srs', 
    9                     'test_geos', 
    10                     'test_measure', 
    11                     'test_spatialrefsys', 
    12                     ] 
     6test_suite_names = [ 
     7    'test_geos', 
     8    'test_measure', 
     9
     10try: 
     11    # GDAL tests 
     12    import django.contrib.gis.gdal 
     13    test_suite_names += [ 
     14        'test_gdal_driver', 
     15        'test_gdal_ds', 
     16        'test_gdal_geom', 
     17        'test_gdal_srs', 
     18        'test_spatialrefsys', 
     19    ] 
     20except ImportError, e: 
     21    print >>sys.stderr, "GDAL not available - no GDAL tests will be run." 
    1322 
    1423test_models = ['geoapp']