def setup_app(command, conf, vars): """Place any commands to setup croner here""" # Don't reload the app if it was loaded under the testing environment load_environment(conf.global_conf, conf.local_conf) # Create the tables if they don't already exist Base.metadata.drop_all(checkfirst=True, bind=Session.bind) Base.metadata.create_all(bind=Session.bind) fixture(Session) Session.commit()