Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[Feature]: Support sharing self-contained HTML reports with embedded screenshots and attachments

Đang mở
#43,771 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
35/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
playwright, typescript
Lĩnh vực
testing

Hướng nghiên cứu

Start by reading the HTML reporter documentation and implementation to find how the report references screenshots, attachments, and traces. Then assess whether embedding those assets or exporting a portable package fits the reporter architecture. Done means recipients can open a shared report and view its results and supported attachments without needing the original project.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

🚀 Feature Request

Currently, when using the HTML reporter, the generated report depends on additional files and directories for screenshots, traces, and other test artifacts. If I download and share only the index.html file with someone, the report may open, but screenshots and other attachments fail to load because their referenced files are not available.

The current workaround is to share the entire playwright-report directory as a ZIP file. The recipient must download and extract it, then run the show-report command from a Playwright project.

Example of the issue:
The screenshot below shows how an image appears broken when the HTML report is shared without its associated assets.

Image
Example

Introduce a configurable option in playwright.config.ts that allows users to generate a self-contained HTML report or a portable report package.

For example, an illustrative configuration could look like this:

reporter: [
  [
    "html",
    {
      outputFolder: "playwright-report",
      selfContained: true,
    },
  ],
],

The selfContained option is only a proposed API name; the implementation could use whichever configuration best fits Playwright's existing architecture.

Ideally, this feature would support one or both of the following approaches:

Single-file HTML report: Embed screenshots, images, and other suitable attachments directly into the HTML report so that users can share one file without broken references.

Portable report export: Provide a built-in way to package the HTML report and all required assets into a single archive or portable artifact that recipients can open without installing Playwright or creating a Playwright project.

The solution should preserve the existing report functionality as much as possible, including test results, failure details, screenshots, and trace access where technically feasible.

Motivation

This feature would make Playwright's HTML reporting workflow more convenient for teams that regularly share test execution results with developers, QA engineers, clients, and other stakeholders.

Key benefits include:

  • Prevent broken screenshots when sharing a standalone HTML report.
  • Eliminate the need to manually ZIP the report directory.
  • Allow recipients to view test results without installing Playwright or accessing the original repository.
  • Simplify the distribution of reports generated by CI/CD pipelines and distributed test runners.
  • Make test execution evidence easier to share, review, and retain independently of the original project.

I understand that embedding large screenshots, videos, and trace files could significantly increase the HTML file size. A portable archive option could be a practical alternative if generating a fully self-contained HTML report is not feasible.

Thank you for considering this feature. It would make Playwright reports significantly easier to share and review outside the original automation environment.

Ngôn ngữ chính
TypeScript
Star
98.5k
Fork
6.7k
Merge trung bình
15 giờ 42 phút
Pull request đã merge (30 ngày)
313

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của microsoft/playwright

Tất cả issue của microsoft/playwright

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.