Experiments Portlet — E2E test suite (incl. flag-off regression of the old flow)
Open
@oidacra is already working on this.
Since Sep 10, 2026.
dotCMS : Experiments
Team : Falcon
Type : Test Automation
- Dominant language
- Java
- Stars
- 970
- Forks
- 486
- Avg merge
- 3d 33m
- Merged PRs (30d)
- 170
Description
Description
There is no E2E coverage for experiments at all today — which also means the migration issue (deleting the old UI) has no safety net without this. Build the Playwright suite for the whole portlet, plus the regression proving the old UVE flow is untouched while FEATURE_FLAG_EXPERIMENTS is off.
Playwright specs in core-web/apps/dotcms-ui-e2e (page objects + fixtures per screen), covering:
List (#36989)
- Site-wide list renders; search by name and page path; status chip filtering with counts; ARCHIVED hidden by default, visible when selected.
- Pagination and column sort (default Modified DESC).
- Deep-links: a URL carrying
filter+status+page+orderbyrestores the exact view; back/forward walks the states; a bare/experimentscarries no params. - Row actions per status (kebab gating follows
AllowedActionsByExperimentStatus): archive, restore, cancel schedule, end, abort, delete — each with confirm and toast.
Create/Update (#37003)
/experiments/new: create by typing a name and selecting a page (autosave POST, URL becomes/:id/configurationwithout a history entry).?url=/indexpreselects the page; invalid value shows a message.- Goal/variants/scheduling edits persist across a reload (autosave PATCH).
- Start with missing fields reveals the 8 validation rules and scrolls to the first error.
- Start → RUNNING (no date) / SCHEDULED (with date); Stop → ENDED; locked state disables the form.
Results (#37004)
- Stats, tabs and summary for a RUNNING and an ENDED experiment.
- Below 10 sessions the table shows the empty state.
- Promote: confirm dialog (RUNNING copy mentions auto-end), promoted state hides Promote buttons.
UVE integration (#37005)
- Flag ON: variant
Edit Contentround-trip — portlet → UVE → back to/experiments/:id/configuration, variant marked as edited. - Flag OFF regression: the old per-page UVE experiments flow works byte-identically — nav item, per-page list, configure, reports.
Fixtures
- Seeded experiments per status (DRAFT/SCHEDULED/RUNNING/ENDED/ARCHIVED) via the REST API in test setup; the manual
cms_layouts_portletsregistration scripted in the suite's global setup.
Acceptance Criteria
- All scenarios above implemented and green in headless mode.
- The deep-link spec fails if URL state stops round-tripping.
- The flag-off regression spec fails if the old UVE flow changes.
- Suite runs in CI on the portlet's affected paths.
Priority
High — gates the migration issue.
Additional Context
- Depends on #36989/#37003/#37004/#37005 to go green, but specs can be written per screen as each lands.
- Out of scope: backend Postman/integration tests (they live with #36823 and #36988); load/perf testing.
- Reference:
docs/testing/E2E_TESTS.md.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.