Skip to content

Commit 375d3c9

Browse files
sspickleclaude
andcommitted
docs(tests): document the LOCAL way to run the e2e suite
The docstring named only the deployed form, which reads as though an App Engine deploy is required. It is not: these tests visit "/" and three static docs pages and assert on titles, visible links and body text — no sign-in flow, no datastore reads — so the docker-compose server the README already documents serves them fine. docker-compose up -d pytest tests/test_e2e.py --base-url http://localhost:8080 -v That turns an 18-test suite from "deploy first" into a fast local loop, which is the useful shape when checking a dependency bump: the app either serves pages or it does not. Also records what the suite needs (pytest-playwright plus `playwright install chromium`) and two honest caveats: the Sign In assertion depends on OAuth config a local stack may lack, and the docs pages are static files, so a green local run says nothing about whether the DEPLOYED docs are current. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G7y9rTA1r8r8EhEnPSQenR
1 parent b4870b0 commit 375d3c9

1 file changed

Lines changed: 16 additions & 2 deletions

File tree

‎tests/test_e2e.py‎

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,22 @@
11
"""
2-
End-to-end tests for a deployed (non-promoted) App Engine version.
2+
End-to-end tests. Any base URL works — these only visit "/" and a few static
3+
docs pages, and assert on titles, visible links and body text. No sign-in flow
4+
and no datastore reads, so a local server is enough.
35
4-
Usage:
6+
Locally (fastest loop — no deploy needed; see README "Run a Local Server"):
7+
docker-compose up -d
8+
pytest tests/test_e2e.py --base-url http://localhost:8080 -v
9+
10+
Against a deployed (non-promoted) App Engine version, before promoting:
511
pytest tests/test_e2e.py --base-url https://VERSION-dot-glowscript.appspot.com -v
12+
13+
Needs pytest-playwright (requirements-test.txt) for the `page`/`base_url`
14+
fixtures, plus the browser itself:
15+
playwright install chromium
16+
17+
Two caveats when running locally: the Sign In assertion depends on OAuth config
18+
a local stack may not have, and the docs pages are static files — so passing
19+
locally says nothing about whether the DEPLOYED docs are current.
620
"""
721
import pytest
822
from playwright.sync_api import Page, expect

0 commit comments

Comments
 (0)