def tearDown(self): db_session.remove() os.unlink(app.config.get('DATABASE_FILE')) # Delete canaries in self.canaries_dir for dir, _, files in os.walk(self.canaries_dir): for f in files: os.unlink(os.path.join(dir, f))
def shutdown_db_session(exception=None): db_session.remove()
def tearDown(self): db_session.remove() os.unlink(app.config.get('DATABASE_FILE'))
def after_return(self, status, retval, task_id, args, kwargs, einfo): db_session.remove()