Repository navigation
feat(attachments): show test attachments on the execution - #106
Merged
Merged
Conversation
Automated tests can now attach logs, HAR files, videos, Playwright traces,
HTML snapshots and images to their results (AnglesHQ/angles, POST
/build/:buildId/attachment). This shows them where the test results are:
- An "Attachments" row of chips on an expanded execution, and on any step
that has its own (e.g. the page HTML at the failing step). The execution
header also counts them. Metadata is fetched once, the first time the
execution is expanded.
- Clicking a chip opens a viewer suited to the file:
- logs and JSON: numbered lines with a "show only lines containing" filter
- HAR: a table of requests with failed ones (4xx/5xx and no response)
highlighted, and a "failed requests only" toggle
- video: a player
- HTML snapshots: the page in an empty-sandbox iframe, so its scripts
never run inside Angles
- images: the picture
- traces and archives: download, with a pointer to trace.playwright.dev
- Every viewer has a Download button that keeps the original file name.
Files are fetched with the session (axios + blob), as the existing manual
attachments are, so this works when the API and UI are on different
origins. Strings are in all five catalogues; colours come from tokens, with
one new token for the HTML snapshot frame's background.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KgQXSUjuLVXmLWxobnMfSf
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.
Summary
Shows the files automated tests attach to their results (AnglesHQ/angles#133): logs, HAR files, videos, Playwright traces, HTML snapshots and images.
Files are fetched with the session (axios plus a blob), like the existing manual-testing attachments, so this works when the API and UI are on different origins. The new list endpoint is called with axios directly, so this PR doesn't need a new
angles-javascript-clientrelease.Design system
--html-snapshot-background, a fixed white behind HTML snapshots, documented next to the other theme-independent overlay tokens..status-*classes, the buttons use.btn-primary/.btn-secondary, and the loading and error states use.app-alert.npm run check-translationspasses.Depends on
AnglesHQ/angles#133 (the API). Merge that first.
Testing
npm run build(the production build) andnpm run check-translationspass.-1, which now shows as "No response" and counts as failed; and the byte formatting for tiny sizes..eslintrc.jsdoesn't load onmaster(eslint-config-airbnbv5 is incompatible with the installedeslint-plugin-react), so I linted the changed files with an equivalent config: airbnb-base, react, jsx-a11y, react-hooks and the repo's own overrides. Onlyfunc-nameswarnings remain, matching the existingconst X = function (props)style.🤖 Generated with Claude Code
https://claude.ai/code/session_01KgQXSUjuLVXmLWxobnMfSf
Generated by Claude Code