Changeset 5531 for django/branches/unicode/django/test
- Timestamp:
- 06/25/07 07:47:19 (2 years ago)
- Files:
-
- django/branches/unicode (modified) (1 prop)
- django/branches/unicode/django/test/utils.py (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/branches/unicode
- Property svnmerge-integrated changed from /django/trunk:1-5460 to /django/trunk:1-5530
django/branches/unicode/django/test/utils.py
r5487 r5531 1 1 import sys, time 2 2 from django.conf import settings 3 from django.db import connection, transaction, backend 3 from django.db import connection, backend, get_creation_module 4 from django.core import management, mail 4 5 from django.core import management, mail 5 6 from django.dispatch import dispatcher … … 89 90 90 91 def create_test_db(verbosity=1, autoclobber=False): 92 # If the database backend wants to create the test DB itself, let it 93 creation_module = get_creation_module() 94 if hasattr(creation_module, "create_test_db"): 95 creation_module.create_test_db(settings, connection, backend, verbosity, autoclobber) 96 return 97 91 98 if verbosity >= 1: 92 99 print "Creating test database..." … … 143 150 144 151 def destroy_test_db(old_database_name, verbosity=1): 152 # If the database wants to drop the test DB itself, let it 153 creation_module = get_creation_module() 154 if hasattr(creation_module, "destroy_test_db"): 155 creation_module.destroy_test_db(settings, connection, backend, old_database_name, verbosity) 156 return 157 145 158 # Unless we're using SQLite, remove the test database to clean up after 146 159 # ourselves. Connect to the previous database (not the test database)
