test: add PDF export endpoint coverage and run in CI (closes #72) by bradjin8 · Pull Request #82 · cppalliance/cppa-cursor-browser · GitHub
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions .github/workflows/tests.yml
9 changes: 9 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,15 @@ def workspace_storage() -> Generator[str, None, None]:
os.environ["CLI_CHATS_PATH"] = prior_cli


@pytest.fixture
def pdf_client():
"""Flask test client for routes that do not read workspace storage (e.g. PDF export)."""
app = create_app()
app.config["TESTING"] = True
app.config["EXCLUSION_RULES"] = []
return app.test_client()


@pytest.fixture
def client(workspace_storage: str):
"""Flask test client bound to the temp workspace_storage fixture."""
Expand Down
126 changes: 126 additions & 0 deletions tests/test_pdf_export.py
Loading