Skip to content

Commit

Permalink
Fix for issue jazzband#129 which would prevent REUSE_DB from working …
Browse files Browse the repository at this point in the history
…reliably when dealing with multiple DB's.
  • Loading branch information
Erik Noren committed Jan 6, 2014
1 parent 4ffb4fa commit d66b422
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions django_nose/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -331,6 +331,11 @@ def setup_databases(self):
creation = connection.creation
test_db_name = creation._get_test_db_name()

# Close the connection ahead of doing a DB check as the connection
# may already be established which will short circuit the
# "should create" tests
connection.close()

# Mess with the DB name so other things operate on a test DB
# rather than the real one. This is done in create_test_db when
# we don't monkeypatch it away with _skip_create_test_db.
Expand Down

0 comments on commit d66b422

Please sign in to comment.