@cyborgtests/reporter-playwright-reports-server

中文文档
2.7.0-beta.1发布于 2025/11/07MITTypeScriptCommonJS零依赖近 30 天下载 6045

Reporter that uploads your blob reports to playwright reports server https://github.com/CyborgTests/playwright-reports-server

此软件包已被标记为弃用

Deprecated: only compatible with Playwright Reports Server < 6.0.0. For server 6.0.0+ install @cyborgtests/reporter (https://www.npmjs.com/package/@cyborgtests/reporter)

原始使用文档

reporter-playwright-reports-server

Playwright reporter that uploads results to Playwright Reports Server - https://github.com/CyborgTests/playwright-reports-server

Install

npm i -D @cyborgtests/reporter-playwright-reports-server

Then, in playwright.config file:

  reporter: [
    // blob reporter is required, produced zip would be uploaded
    ['blob', { outputFile: 'test-results/blob.zip' }],
    [
      '@cyborgtests/reporter-playwright-reports-server',
      {
        // true by default. Use this if you need to skip this reporter for some cases (local executions for example)
        enabled: true,
        /**
         * Your server url
         * @see https://github.com/CyborgTests/playwright-reports-server
         */
        url: 'https://your server instance.com',
        // Set token if your server instance has authentication enabled
        token: '1234',
        // Timeout for reporter HTTP requests to finish, default 60000ms, increase if you have slow server and big requests.
        requestTimeout: 60000,
        // Relative path to your blob. Required.
        reportPath: 'test-results/blob.zip',
        // Any custom metadata to attach to this blob (strings)
        resultDetails: {
          branch: process.env.CI_COMMIT_BRANCH,
          foo: 'bar',
          bar: 'baz'
        },
        // Automatically trigger HTML report generation after tests finish. Shards supported. false by default
        triggerReportGeneration: false
      },
    ],
  ],

Then run your tests, if you see [ReporterPlaywrightReportsServer] 🎭 HTML Report is available at: ... - your blob results were successfully sent to server!

Shards

Auto-generation of report after all shards completed is supported. But you must specify testRun and triggerReportGeneration: true:

  • In reporter configuration pass
resultDetails: {
  ...
  // testRun required, it should be same for all shards!
  testRun: 'my-awesome-test-run-12'
  ...
},
triggerReportGeneration: true

Reporter passes current shard number and total shard count to server, and after all shards uploaded - report will be generated by server for all blobs in this testRun

版本与发布记录

@cyborgtests/reporter-playwright-reports-server 共发布 21 个版本,首次发布于 2024/09/10;过去 12 个月发布了 0 个版本。

版本发布日期距今
2.7.0-beta.1latest2025/11/071 年前
2.6.12025/11/031 年前
2.6.02025/10/311 年前
2.4.12025/10/161.1 年前
2.4.02025/09/231.1 年前
2.3.42025/09/191.1 年前

关于 @cyborgtests/reporter-playwright-reports-server 的常见问题

@cyborgtests/reporter-playwright-reports-server 是什么?

Reporter that uploads your blob reports to playwright reports server https://github.com/CyborgTests/playwright-reports-server注意:该包已被作者标记为弃用——Deprecated: only compatible with Playwright Reports Server < 6.0.0. For server 6.0.0+ install @cyborgtests/reporter (https://www.npmjs.com/package/@cyborgtests/reporter)

如何安装 @cyborgtests/reporter-playwright-reports-server?

在项目目录运行 npm install @cyborgtests/reporter-playwright-reports-server,或使用 pnpm add / yarn add / bun add。它还需要宿主项目提供 peer 依赖:@playwright/test(^1.37.0)。npm 7 及以上与 pnpm 8 及以上默认会自动安装必需的 peer 依赖,Yarn 需要手动安装。

@cyborgtests/reporter-playwright-reports-server 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@cyborgtests/reporter-playwright-reports-server 支持 ESM 还是 CommonJS?

以 CommonJS 形式发布,可以直接 require();在 ES Module 项目中也可以用 import 引入(Node.js 会把 module.exports 作为默认导出)。

@cyborgtests/reporter-playwright-reports-server 可以商用吗?

@cyborgtests/reporter-playwright-reports-server 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@cyborgtests/reporter-playwright-reports-server 的下载量有多少?

根据 npm 官方下载统计,@cyborgtests/reporter-playwright-reports-server 在 2026/10/11 – 2026/11/09 这 30 天内被下载 6,045 次,日均约 202 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@cyborgtests/reporter-playwright-reports-server 还在维护吗?

最新版本 2.7.0-beta.1 发布于 2025/11/07(1 年前);至今共发布 21 个版本,其中过去 12 个月发布了 0 个;首次发布于 2024/09/10。作者已将其标记为弃用,新项目建议寻找替代方案。