""" Pytest configuration and fixtures for Visual Workflow Builder tests """ import pytest from app import app, db @pytest.fixture def client(): """Create a test client for the Flask app""" app.config['TESTING'] = True app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///:memory:' with app.test_client() as client: with app.app_context(): db.create_all() yield client db.drop_all() @pytest.fixture def app_context(): """Create an application context for tests""" with app.app_context(): db.create_all() yield app db.drop_all()