Permalink
Browse files

Wrap up DB teardown in `after_all` in a try/except.

  • Loading branch information...
1 parent 7a1327e commit 01ccc307a2a8c666230ed59b7bfcda1fb15a3009 @plasticine committed Feb 12, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 tests/environment.py
View
@@ -23,8 +23,11 @@ def before_all(context):
def after_all(context):
# clean up django test DB
- db.close_connection()
- db.connection.creation.destroy_test_db(old_name, verbosity=0)
+ try:
+ db.close_connection()
+ db.connection.creation.destroy_test_db(old_name, verbosity=0)
+ except Exception, e:
+ pass
teardown_test_environment()
def before_feature(context, feature):

0 comments on commit 01ccc30

Please sign in to comment.