projects
/
mediagoblin.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
16b8e3a
)
Drop our scoped session sooner to prevent SQLAlchemy re-binding warnings.
author
Brett Smith
<brettcsmith@brettcsmith.org>
Sun, 8 Jul 2012 15:00:36 +0000
(11:00 -0400)
committer
Brett Smith
<brettcsmith@brettcsmith.org>
Sun, 8 Jul 2012 15:00:36 +0000
(11:00 -0400)
mediagoblin/tests/tools.py
patch
|
blob
|
blame
|
history
diff --git
a/mediagoblin/tests/tools.py
b/mediagoblin/tests/tools.py
index 5b4e3746202cbf9b872e2faff2cbdf1db7de21fc..bf40ea8b5e433861c953f12988990220a48f4888 100644
(file)
--- a/
mediagoblin/tests/tools.py
+++ b/
mediagoblin/tests/tools.py
@@
-116,6
+116,9
@@
def get_test_app(dump_old_app=True):
if MGOBLIN_APP and not dump_old_app:
return MGOBLIN_APP
+ Session.rollback()
+ Session.remove()
+
# Remove and reinstall user_dev directories
if os.path.exists(TEST_USER_DEV):
shutil.rmtree(TEST_USER_DEV)
@@
-135,9
+138,6
@@
def get_test_app(dump_old_app=True):
test_app = loadapp(
'config:' + TEST_SERVER_CONFIG)
- Session.rollback()
- Session.remove()
-
# Re-setup celery
setup_celery_app(app_config, global_config)