Repository navigation
Take the ticket branches page's five screenshots automatically - #633
Merged
Merged
Conversation
The last five of the guide's pictures that no script took (#561): a site with two tickets, the card of a site's other tickets with one linked and with none, the question asked when a ticket is linked over an edit on trunk, and the notice that the edit came along. The automatic tier is now twenty-six, and one picture, of a site being set up, is still a person's. They are taken on the checkout fixture. A ticket in the list has an age ("Edited 1 day ago"), which a shot cannot give it through the app: every ticket it left would have been left just now. So the tickets a site was left with are the fixture's, a branch where trunk was and the record the app writes of one, with the hours chosen well inside the wording they come out as. The picture of a site with two tickets is of a window taller than the harness opens, since the second card is at the foot of the page, and is refused if the page outgrows it. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…xture's trunk From the review. The notice's picture waits for the line that says there is one unsubmitted change, which a read of its own brings after the link has ended and which was missing from a picture taken before it. The pictures of a ticket's row wait for its buttons to be ones that can be pressed, where they waited for them to be on the page; a trial click is the wait, and the pointer is taken away after it. The checkout fixture's trunk commit is dated as the seeded sites' code is, two days back, where it was dated the moment it was made: the site's details said its code was newer than the site, and a ticket left a day ago had branched from today's trunk. CONTRIBUTING.md said a running server and a real diff need a person to photograph. One picture does, of a site being set up. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
From the second review. The harness dated its trunk commit by running the Git binary itself, with the commit's identity written out again: a third way to the binary, beside the app's and the tests'. commitFiles takes the date instead, and adds the committer's date to the one command's environment the way git-binary.cjs has a variable added. A comment said a row's buttons can be pressed after the card has read the ticket, which the app does not promise, and one wait the trial click already does is gone. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configuration
You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Fourth part of #561. After #631 six of the guide's screenshots were still a person's to take, and five of those no script took at all: the pictures on the ticket branches page. Settings (#559) and dark mode (#560) will each change every picture in the guide again, so a picture that takes a person is one that will be stale. This takes the five automatically, on the checkout fixture of #631.
What changes
Five shots join the automatic tier, which is now twenty-six of twenty-seven:
site-with-tickets: a Core site with a ticket in hand and the card of its other tickets at the foot of the page.ticket-list-card: that card, with a ticket linked.ticket-list-unlinked: the same card with none linked, two tickets in it.trunk-work-question: what the app asks when a ticket is linked over an edit on trunk.carried-work-notice: the ticket's card after the edit came along.Tickets the site was left with are the fixture's. A row in the list has an age ("Edited 1 day ago"), which a shot cannot give it through the app: every ticket it left would have been left just now. So for these variants the fixture makes what the app makes when a ticket is started and left with nothing done: a branch where trunk was, and the record of it (which ticket, where it branched, when it was last worked on). The hours are chosen well inside the wording they come out as, so a picture is the same at any time of day.
The checkout fixture's trunk commit is dated as the seeded sites' code is, two days back. It was dated the moment it was made, so a site's details said its code was newer than the site.
What the harness gained for them:
site-with-ticketsis taken in a window 1480 high, since its second card is at the foot of the page).One change outside the harness:
commitFilesintests/unit/helpers/git.cjstakes adate. It is the fixture layer the tests build their repositories with; no test passes the option, and without it the command is the one it was.Beside the images: the alt text of the five, and the sentence in
CONTRIBUTING.mdabout which pictures need a person.Not in this pull request:
setup-wizard, the one picture still taken by a person. It can be taken automatically too, and is the next pull request, with the removal of the live tier it leaves empty.How to test this
Platforms: macOS to reproduce the committed images; the harness is written to run on any, and I have run it on macOS only. Nothing here ships in the app.
From the repository root, on the current head, after
npm ci:✓ <name>.png, and exits 0. It opens the app's window fourteen times; do not type while it runs, and no browser tab opens.git statususually shows nothing. Some runs show one or two images changed by a handful of pixels on a rounded corner (4 of the 17 runs I made today, always in a picture older than this change, 12 pixels in the one I measured); take it again and it is gone. That is more often than the one in ten Take four more of the guide's screenshots automatically, and make a retake change less #621 measured: there are more pictures to a run now.ticket-list-unlinked.png: two rows, #60000 "Edited 3 hours ago" above #61002 "Edited 1 day ago", each with Continue working and Delete this ticket’s work, none greyed.carried-work-notice.png: a blue notice that 1 uncommitted change came along into #60000, and under it "You have 1 unsubmitted change for ticket #60000".site-with-tickets.png: under Details, "Trunk as of" is two days before the run, the day "Created" gives.What must not have happened: a button in a ticket's row drawn greyed or as if the pointer were on it; anything asked of GitHub or Trac; a folder named
wpct-docs-fixtureorwpct-userdata-…left in the temporary directory after the run.What I could not test: Windows. And on Windows the fixture is under the user's temporary folder, so a whole-window picture taken there would have the user's name in "Local path"; that was so before this change, and the committed pictures are taken on macOS, where the path is
/tmp/wpct-docs-fixture/….Risks and limitations
npm testpasses, and I checked by hand that a commit made with a date carries it as author's and committer's, and that one made without is dated now.Related
Part of #561, which is part of #542. Follows #631.
Design decisions and alternatives considered
Review outcome (required — see AGENTS.md)
Pass 1: 3 [fix here] · 3 [follow-up]. Pass 2 (on the fix-up): 2 [fix here] · 0 [follow-up]. All 5 fixed, 2 follow-ups taken here, 1 left.
Both passes were made before the rebase onto #631's merge, on commits that are the same changes as these; the heads below are the ones reviewed.
551457eon91fffb0, the head Take five more of the guide's screenshots automatically, on a fixture that is a real checkout #631 merged; the five images opened and each alt text read against its picture, the seeded record compared with what linking and leaving a ticket write, every request the five flows make traced to a stand-in or to something local; ESLint run on the harness,npm testand the shots not run; 3 [fix here], 3 [follow-up].CONTRIBUTING.mdsaid a running server and a real diff need a person; the checkout's trunk was dated the day of the run, newer than the site.ticket-branches.md: "each row is a Continue working on #NNNNN link" and "Continue working on" twice more (it is a Continue working button); "edited 2 days ago" (capitalised, and the pictures' are a day and three hours); "Delete this ticket's" with a straight apostrophe; "came along into #62281" and "1 unsubmitted change for ticket #29798" (the pictures' ticket is #60000); and the delete question, which the app now words "Delete all work on ticket #61002?" and "This can’t be undone."c0cd36eon91fffb0; the dated commit followed through the fixture's order and the app's reading of trunk's date, the trial click checked against how the row's buttons are disabled, the two retaken images opened; ESLint run on the harness,npm testand the shots not run; 2 [fix here], 0 [follow-up].c0cd36e → ce66772is those fixes, not reviewed again; it is what changestests/unit/helpers/git.cjs. The three commits were then rebased onto Take five more of the guide's screenshots automatically, on a fixture that is a real checkout #631's merge with no conflict and are1765fc9,48b78ea,f56f33f. On that head:npm run lintandnpm testpass, and a retake of the tier changed no image.Implementation notes
scripts/screenshots/fixtures.cjs:OTHER_TICKET,PARKED_TICKETS;buildRepoFixturemakes the branches and writes their record; the trunk commit datedFRESH.trunkDate.scripts/screenshots/shots.cjs:waitUntilPressable,fixTheLine,askToLinkOverAnEdit; the five shots.tests/unit/helpers/git.cjs:gitandgitOktake an environment,commitFilesadate.Screenshots or recording
The images are the change:
docs/public/screenshots/in the diff, which GitHub shows before and after.🤖 Generated with Claude Code