We weren't committing to the database in the correct spot, so the delete wasn't sticking, and we were ending up with test workflows showing up in the main interface.
This commit is contained in:
parent
e4140dec9f
commit
628a587d97
|
@ -88,10 +88,10 @@ class WorkflowService(object):
|
|||
# Also, delete any test study or user models that may have been created.
|
||||
for study in db.session.query(StudyModel).filter(StudyModel.user_uid == "test"):
|
||||
StudyService.delete_study(study.id)
|
||||
db.session.commit()
|
||||
user = db.session.query(UserModel).filter_by(uid="test").first()
|
||||
if user:
|
||||
db.session.delete(user)
|
||||
db.session.commit()
|
||||
|
||||
@staticmethod
|
||||
@timeit
|
||||
|
|
Loading…
Reference in New Issue