Commits

Matthew Schinckel committed 207b62f

Fixes to work with most recent releases of django_coverage.

Comments (0)

Files changed (2)

 History
 ----------
 
-0.9.6
+0.9.7
 ~~~~~
-Allow for using this field with tests that use freezgun.
+Remove freezegun workarounds.
 
 0.9.4
 ~~~~~
     global_settings.STATIC_ROOT = global_settings.MEDIA_ROOT
     
     global_settings.SECRET_KEY = '334ebe58-a77d-4321-9d01-a7d2cb8d3eea'
-    if os.environ.get('COVERAGE', None):
-        global_settings.TEST_RUNNER = 'django_coverage.coverage_runner.CoverageRunner'
-    global_settings.COVERAGE_REPORT_HTML_OUTPUT_DIR =os.path.join(BASE_PATH, '.coverage')
+    global_settings.COVERAGE_REPORT_HTML_OUTPUT_DIR = os.path.join(BASE_PATH, '.coverage')
     global_settings.COVERAGE_USE_STDOUT = True
     global_settings.COVERAGE_PATH_EXCLUDES = ['.hg', 'templates', 'tests', 'sql', '__pycache__']
     
-    
-    from django.test.utils import get_runner
-    test_runner = get_runner(global_settings)
+    if os.environ.get('COVERAGE', None):
+        from django_coverage import coverage_runner
+        test_runner = coverage_runner.CoverageRunner
+    else:
+        from django.test.utils import get_runner
+        test_runner = get_runner(global_settings)
 
     test_runner = test_runner()
     failures = test_runner.run_tests(['jsonfield'])