Exemplo n.º 1
0
def db(app, request):
    def fin():
        flask_db.session.close()
        flask_db.drop_all()
        flask_db.get_engine(app).dispose()
    request.addfinalizer(fin)

    flask_db.drop_all()
    flask_db.create_all()
    return flask_db
Exemplo n.º 2
0
def db(app, request):
    def fin():
        flask_db.session.close()
        flask_db.drop_all()
        flask_db.get_engine(app).dispose()
    request.addfinalizer(fin)

    flask_db.drop_all()
    flask_db.create_all()
    return flask_db
Exemplo n.º 3
0
 def fin():
     flask_db.session.close()
     flask_db.drop_all()
     flask_db.get_engine(app).dispose()
Exemplo n.º 4
0
 def fin():
     flask_db.session.close()
     flask_db.drop_all()
     flask_db.get_engine(app).dispose()