Post screenshots and Lighthouse scores on each merge request from GitLab CI #392
Labels
No labels
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
spec
wayfinder:grilling
wayfinder:map
wayfinder:prototype
wayfinder:research
wayfinder:task
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
amaurycoudr/chess-project#392
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What to build
Bring back on GitLab the two review aids that GitHub's
preview.ymlgave every pull request and that the move to GitLab left out (infra/gitlab/DECISIONS.md, "Not ported"):apps/e2e/screenshotssuite (pnpm --filter @chess/e2e screenshots), shown side by side in one merge request note./and/local, on mobile and desktop, audited against the review app withlighthouse@13.5.0, scores gathered into one merge request note.Both stay informational: neither fails the pipeline nor blocks a merge.
How
reviewininfra/gitlab/vps/deploy.gitlab-ci.yml, skipped on docs-only merge requests like the other preview jobs.pr-screenshots-style branch, which the GitHub push mirror would carry.<!-- chess-screenshots -->,<!-- chess-lighthouse -->), created once and updated on each pipeline, throughPOST/PUT /projects/:id/merge_requests/:iid/notes.Prerequisite (owner)
A project access token
mr-notes, role Reporter, scopeapi, stored as the masked CI/CD variableMR_NOTES_TOKEN: the job token cannot write notes.Acceptance
apps/frontgets a screenshots note with before/after images and a Lighthouse note with the 4 scores.n/ain its cell and leaves the pipeline green.Reference
GitHub's version:
.github/workflows/preview.yml(jobsscreenshots,screenshots-commit,lighthouse,lighthouse-report,lighthouse-comment), still in the repo though disabled.mentioned in commit
948e96c09dmentioned in merge request !509
mentioned in merge request !510
mentioned in commit
02444676dd