BRIEF §20.2 asks for visual regression of the --capture screenshots with a pixel-diff tolerance; CI only published them. `Titano.Tools screenshots diff <dir>` compares every PNG with tests/visual/baselines: a pixel differs when a channel moves by more than --tolerance (8 of 255), and a screen fails when more than --max-diff of its pixels differ (0.05 %), when its size changed or when a baseline lost its screen; a screen without a baseline only warns. It writes a diff image per screen with differing pixels (the baseline faded, the differences magenta) and a Markdown summary, also to the GitHub job summary. `screenshots accept <dir>` copies screenshots over the baselines. The baselines folder starts with its README; the pictures come later from ci-screenshots. The captures were not reproducible: the sample's jobs, renders, transfers, cards, trash and remote sequences were dated from the clock, the Library timeline and the Archive heatmap laid out around today, the Uploader captured in the computer's language and an indeterminate bar animated. The sample now dates everything from SampleData.Now, --capture freezes the new AppClock there, formats are English, and the new Motion attached property (off in the captured windows) keeps the indeterminate sweep still in the middle. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
2.2 KiB
Screenshot baselines
The approved look of every screen, one PNG per --capture screenshot (<screen>-<theme>.png, as Titano.exe,
Titano.Uploader.exe and Titano.Setup.exe --capture <dir> write them). CI compares each new screenshot with the
file of the same name here (BRIEF §20.2, visual regression with a pixel-diff tolerance):
dotnet run --project src/Titano.Tools -- screenshots diff out/screenshots --out out/screenshot-diff
- A pixel differs when one of its channels moves by more than
--tolerance(default 8 of 255); a screen fails when more than--max-diffof its pixels differ (default 0.0005, that is 0.05 %), when its size changed, or when a baseline here has no screenshot any more. - A screenshot without a baseline only warns.
out/screenshot-diffgets<screen>-diff.pngfor every screen with differing pixels (the baseline faded to grey, the differences magenta) andsummary.md; CI uploads them as thescreenshot-diffartifact and adds the summary to the job page.
The pictures are reproducible
The capture runs on sample data whose clock stands at SampleData.Now (2026-10-02 10:18 UTC), in English with English
formats and with animations off, so the same code draws the same pixels on any day. Two things still come from the
machine:
- the time zone: times are shown in local time, and the baselines are made on the CI runner (
windows-latest, UTC); - a few measured values: the server's response time and the time and duration of the last sync comparison. They change a few dozen pixels, well inside the allowed fraction.
Adding or updating baselines
Take them from CI, never from a local run (fonts, scaling and the time zone differ). Every same-repository pull request
pushes its screenshots to the ci-screenshots branch (one commit, the PNGs at its root). After checking them:
git fetch origin ci-screenshots
git worktree add ../ci-screenshots origin/ci-screenshots
dotnet run --project src/Titano.Tools -- screenshots accept ../ci-screenshots
git worktree remove ../ci-screenshots
screenshots accept <dir> copies every PNG of <dir> here. Commit only the screens whose change is intended, and delete
the baseline of a screen that no longer exists.