Пример #1
0
def dropdb():
    """Drops all tables and constraints from the database."""
    db.drop_all()
Пример #2
0
def syncdb():
    """Synchronize the models with the database."""
    app = Application()
    with app.app_context():
        db.drop_all()
        db.create_all()
Пример #3
0
def dropdb():
    """Drops all tables and constraints from the database."""
    db.drop_all()
Пример #4
0
def pytest_unconfigure(config):
    app = Application('test')
    with app.app_context():
        db.drop_all()
Пример #5
0
def syncdb():
    """Synchronize the models with the database."""
    app = Application()
    with app.app_context():
        db.drop_all()
        db.create_all()