コード例 #1
0
def db(request, app):
    with app.app_context():
        _database.create_all()

    @request.addfinalizer
    def _drop():
        with app.app_context():
            _database.drop_all()
コード例 #2
0
ファイル: conftest.py プロジェクト: tehasdf/flaskexample
def db(request, app):
    with app.app_context():
        _database.create_all()

    @request.addfinalizer
    def _drop():
        with app.app_context():
            _database.drop_all()
コード例 #3
0
ファイル: commands.py プロジェクト: tehasdf/flaskexample
def createdb():
    db.create_all()
    generic_db.create_all()
コード例 #4
0
ファイル: commands.py プロジェクト: tehasdf/flaskexample
def createdb():
    db.create_all()
    generic_db.create_all()