Automated test suite for VC, built with Playwright and pytest.
- Python 3.13+
- Git
git clone <repo-url>
cd vc-auto-testsWindows
python -m venv .venv
.venv\Scripts\activateLinux / macOS
python3 -m venv .venv
source .venv/bin/activatepip install -e .playwright installThe test dataset is seeded into the backend via WebAPI. Run this once against a fresh environment (and whenever the dataset changes):
python -m dataset.dataset_manager --seed --mode ciPass entity names to seed only a subset (order is taken from the manifest, not the command line):
python -m dataset.dataset_manager --seed stores pages pages_contentSome entities need a follow-up action that the create API cannot express
directly — a state transition, a workflow trigger, etc. These live in
dataset/scripts/ and are run after seeding, on demand.
| Script | Purpose | Command |
|---|---|---|
set_builder_page_status |
Page-builder pages are always seeded as Draft (publish/archive is a backend workflow, not a settable field). This script transitions one page to a target status. |
python -m dataset.scripts.set_builder_page_status --page-id <id> --status <Published|Archived> |
Note: seeding leaves every page in
Draft— the create API ignores astatusfield, so publishing and archiving must go through the workflow endpoints. Runset_builder_page_statuswith the grouped page ids (the stable key the API uses — page names are not guaranteed unique).--page-idaccepts several ids at once:python -m dataset.dataset_manager --seed --mode ci python -m dataset.scripts.set_builder_page_status --status Published --page-id \ acme-store-grouped-page-about-store \ acme-store-grouped-page-spring-sale \ acme-store-grouped-page-seasonal-lookbook \ acme-store-grouped-page-wholesale-offers \ acme-store-grouped-page-partner-portal \ acme-store-grouped-page-summer-preview python -m dataset.scripts.set_builder_page_status --status Archived --page-id \ acme-store-grouped-page-legacy-catalogThat leaves one page per status filter used by the page-builder E2E suite:
Page Lands in Exercises our-teamDraft draft filter spring-sale,about-storeActive plain Publishedbadgeseasonal-lookbookActive Published+Scheduled(current date window)wholesale-offersActive Published+Personalized(user group)partner-portalActive Published+Personalized(organization)summer-previewPending Published+Scheduled(future start date)legacy-catalogArchived archived filter
createdDate/modifiedDatecannot be seeded — the API echoes them back in the POST response but assigns its own values, so the pages all carry seed-time audit dates.
The seed command accepts --mode dev (default, per-item detail) or --mode ci
(summary output); set_builder_page_status accepts the same --mode flag.
pytest