@sentinelqa/playwright-reporter 0.1.51 → 0.1.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,52 +1,53 @@
1
1
  # Playwright Reporter
2
2
 
3
- After every failed run, reporter prints a shareable debugging link:
3
+ After every failed Playwright run, Sentinel gives you:
4
4
 
5
- Sample run: https://app.sentinelqa.com/share/1f343d91-be17-4c14-b1b9-2d4e8ef448d2
5
+ - a clear CLI diagnosis
6
+ - a shareable debugging link
7
+ - grouped failures by likely root cause
6
8
 
7
- Open it to inspect failures instantly or share it in Slack, PRs, or GitHub issues.
9
+ Sample run: https://app.sentinelqa.com/share/1f343d91-be17-4c14-b1b9-2d4e8ef448d2
8
10
 
9
11
  [![npm](https://img.shields.io/npm/v/@sentinelqa/playwright-reporter)](https://www.npmjs.com/package/@sentinelqa/playwright-reporter)
10
12
  [![downloads](https://img.shields.io/npm/dm/@sentinelqa/playwright-reporter)](https://www.npmjs.com/package/@sentinelqa/playwright-reporter)
11
13
  [![license](https://img.shields.io/npm/l/@sentinelqa/playwright-reporter)](./LICENSE)
12
14
 
13
- From failed CI run root cause in seconds.
14
- Get a shareable Playwright debugging link with traces, screenshots, and failure context — no setup required.
15
-
16
- Works with no account or API key required.
15
+ From failed CI run to root cause in seconds.
17
16
 
18
- Use it to get a shareable hosted run link from CI or local development, then upgrade to Sentinel Cloud for richer history and intelligence.
17
+ Works with no account and no API key.
19
18
 
20
19
  ![Sentinel Report Example](./docs/screenshot2.png)
21
- ![CLI Quick Diagnosis](./docs/CLI1.png)
20
+ ![CLI Quick Diagnosis](./docs/CLI2.png)
22
21
 
23
- ## Features
22
+ ## What It Does
24
23
 
25
- - Free hosted debugging links by default, with no account or API key required
26
- - Public run page that opens on unified failures across the run
27
- - Within-run failure grouping so repeated failures collapse into one issue
28
- - Public failure pages with screenshots, evidence, parsed errors and light summaries
29
- - Copyable share actions for Slack, PRs, and debugging handoff
30
- - Deterministic quick diagnosis in the terminal after failed runs
31
- - Playwright traces, screenshots, videos and logs uploaded automatically
32
- - 48-hour public share links on the free hosted flow
33
- - Works with existing Playwright reporter setup
34
- - Optional live failure capture for richer Sentinel Cloud analysis
35
- - CI run history, retention, and deeper AI debugging in Sentinel Cloud
24
+ Sentinel explains Playwright failures locally, groups them into real root causes, and gives you a shareable link to inspect the run.
36
25
 
37
- ## Why this exists
26
+ The open-source reporter is focused on one job:
38
27
 
39
- Debugging Playwright failures usually means downloading traces, screenshots, and logs separately from CI.
28
+ - tell you what broke
29
+ - show why it failed
30
+ - point to the likely root cause
31
+ - tell you what to check next
40
32
 
41
- Reporter uploads those artifacts into a single hosted Sentinel run page so you can open one link, inspect failures fast, and share that link with the rest of the team.
33
+ ## Features
34
+
35
+ - Free hosted debugging links by default
36
+ - Deterministic CLI diagnosis after failed runs
37
+ - Failure grouping by likely root cause
38
+ - Shared run page with traces, screenshots, videos, and logs
39
+ - Failure pages that explain what broke, why, where, and what to do next
40
+ - Better timeout, actionability, assertion, navigation, and backend failure wording
41
+ - Public share links that are easy to paste into Slack, PRs, and issues
42
+ - Works with existing Playwright reporter setup
42
43
 
43
- ## Why teams use the free version
44
+ ## Why Teams Use It
44
45
 
45
- - Drop one wrapper into `playwright.config.ts` and keep running `npx playwright test`
46
- - Get a hosted Sentinel debugging link automatically on failed runs
47
- - Share one public URL in Slack, PRs, or GitHub issues instead of passing around raw CI artifacts
48
- - See unified failures, grouped failure patterns, screenshots, and evidence in one place
49
- - Let teammates inspect the failure without needing your CI system or local machine
46
+ - You do not need to open raw logs first
47
+ - Repeated failures collapse into a smaller number of real issues
48
+ - The CLI explains the failure immediately in CI
49
+ - Anyone on the team can open the same shared debugging link
50
+ - The hosted report keeps the explanation, artifacts, and grouped failures in one place
50
51
 
51
52
  ## Requirements
52
53
 
@@ -55,14 +56,6 @@ Reporter uploads those artifacts into a single hosted Sentinel run page so you c
55
56
 
56
57
  ## Quick Start
57
58
 
58
- `withSentinel()` is the default setup for everyone:
59
-
60
- - best for free and local users
61
- - zero-friction setup
62
- - hosted Sentinel report link is generated automatically
63
- - no `SENTINEL_TOKEN` required
64
- - AI summaries use trace and reporter evidence, but are less precise than live page capture
65
-
66
59
  Install:
67
60
 
68
61
  ```bash
@@ -91,80 +84,91 @@ export default withSentinel(
91
84
  );
92
85
  ```
93
86
 
94
- ## Example
95
-
96
- Run your Playwright tests:
87
+ Run your tests:
97
88
 
98
89
  ```bash
99
90
  npx playwright test
100
91
  ```
101
92
 
102
- If tests fail, Sentinel uploads a hosted debugging report and prints the shareable link in the terminal.
93
+ If tests fail, Sentinel uploads the run and prints a shareable link in the terminal.
103
94
 
104
- Open the hosted report to inspect:
95
+ ## CLI Output
105
96
 
106
- - failed tests across jobs
107
- - within-run grouped failures
108
- - screenshots and videos
109
- - trace links
110
- - parsed failure details
111
- - light summaries
112
- - shareable public debugging page
97
+ On failed runs, Sentinel prints a compact diagnosis that answers:
113
98
 
114
- The free hosted public flow is designed for distribution:
99
+ 1. What failed?
100
+ 2. What caused it?
101
+ 3. Where is it?
102
+ 4. What should I check next?
115
103
 
116
- - one shareable debugging link per run
117
- - public read-only pages
118
- - fast enough to use in CI comments and Slack threads
119
- - clear upgrade path into a full Sentinel workspace when teams want history, retention, and deeper analysis
104
+ Typical output:
120
105
 
121
- ## Modes
106
+ ```text
107
+ Sentinel diagnosis
108
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
122
109
 
123
- ### Free hosted mode
110
+ RECURRING FAILURE (12 previous runs)
124
111
 
125
- If `SENTINEL_TOKEN` is not set, the reporter uploads the run to a hosted public Sentinel report and prints the shareable URL.
112
+ 4 failures (grouped)
113
+ Collapsed into 2 real issues
126
114
 
127
- This free public flow includes:
115
+ Issue 1: Blocked click on getByRole('button', { name: 'Save' }) (3 tests)
116
+ Cause: .modal-backdrop intercepted pointer events before the click completed
117
+ Where: checkout.spec.ts:22; billing.spec.ts:41
118
+ Failing step: Click on getByRole('button', { name: 'Save' }) selector
119
+ Blocker: .modal-backdrop intercepting pointer events
120
+ Likely fix: dismiss or wait for .modal-backdrop to disappear before clicking Save
121
+ Impact: 3 tests failing with same root cause
128
122
 
129
- - hosted run page
130
- - hosted failure pages
131
- - grouped failures inside the run
132
- - light summaries
133
- - copy/share actions
134
- - 48-hour share links
123
+ Issue 2: Assertion mismatch (getByTestId('metric-pass-rate')) (1 test)
124
+ Cause: getByTestId('metric-pass-rate') showed "88%" instead of "100%"
125
+ Where: app.spec.ts:68
126
+ Failing step: Expect text on getByTestId('metric-pass-rate') selector
127
+ Expected: 100%
128
+ Received: 88%
129
+ Likely fix: fix the UI state or data behind getByTestId('metric-pass-rate') so it shows "100%"
130
+ Impact: 1 test failing with this root cause
131
+ ```
135
132
 
136
- ### Workspace mode
133
+ On passed runs, Sentinel stays quiet unless there is a strong risk signal worth surfacing.
137
134
 
138
- If `SENTINEL_TOKEN` is set, the reporter uploads into your Sentinel workspace instead of the free hosted public flow.
135
+ ## What The Shared Report Shows
139
136
 
140
- ```bash
141
- SENTINEL_TOKEN=your_project_ingest_token npx playwright test
142
- ```
137
+ The hosted report is simple on purpose.
143
138
 
144
- For local runs outside CI, Sentinel will use your local git metadata automatically when available.
139
+ It focuses on:
145
140
 
146
- ## What `withSentinel()` does
141
+ - grouped failures
142
+ - explanation of why each issue failed
143
+ - affected tests
144
+ - artifacts
145
+ - recent history
147
146
 
148
- - Preserves your existing reporter configuration
149
- - Injects a Playwright JSON reporter if one is missing
150
- - Sets sensible artifact defaults:
151
- - trace: `retain-on-failure`
152
- - screenshot: `only-on-failure`
153
- - video: `retain-on-failure`
154
- - Uploads the run to hosted Sentinel at the end of the test run
147
+ Open the link to inspect:
155
148
 
156
- ## Recommended Cloud Setup
149
+ - failures grouped by likely root cause
150
+ - whether multiple failures appear related
151
+ - the best available explanation for each issue
152
+ - screenshots, traces, videos, and logs
153
+ - direct links you can share with the rest of the team
157
154
 
158
- If you use Sentinel Cloud and want the best AI summaries and fix suggestions, keep `withSentinel()` in your Playwright config and add the live capture fixture.
155
+ ## Free Hosted Mode
159
156
 
160
- Why:
157
+ If `SENTINEL_TOKEN` is not set, the reporter uploads the run to a free hosted Sentinel report and prints the public share URL.
161
158
 
162
- - `withSentinel()` alone works from reporter and trace data
163
- - a Playwright reporter does not get the live `page` fixture
164
- - the live capture fixture lets Sentinel collect richer DOM and code context at the exact failure moment
165
- - this is required for the highest-quality DOM-aware patches
159
+ This free flow includes:
166
160
 
167
- Create one shared test wrapper:
161
+ - CLI diagnosis
162
+ - hosted run page
163
+ - grouped failures
164
+ - failure explanation
165
+ - public share links
166
+
167
+ ## Optional Richer Capture
168
+
169
+ `withSentinel()` works on its own and is the simplest setup.
170
+
171
+ If you want richer failure evidence, you can also attach the failure capture fixture:
168
172
 
169
173
  ```ts
170
174
  // tests/test.ts
@@ -175,20 +179,28 @@ export const test = attachSentinelFailureCapture(base);
175
179
  export { expect };
176
180
  ```
177
181
 
178
- Then import from that file in your specs instead of `@playwright/test`:
182
+ Then import from that file in your specs:
179
183
 
180
184
  ```ts
181
185
  import { test, expect } from "./test";
182
186
  ```
183
187
 
184
- Use this cloud setup when you want:
188
+ This improves the quality of:
189
+
190
+ - blocked action diagnosis
191
+ - assertion mismatch diagnosis
192
+ - timeout explanations
193
+ - DOM and state evidence in the report
185
194
 
186
- - best AI summaries
187
- - best fix suggestions
188
- - richer DOM-aware diagnosis
189
- - more reliable code patches grounded in real page state
195
+ ## What `withSentinel()` Does
190
196
 
191
- Free and local-only users do not need this. The standard `withSentinel()` setup remains the simplest path and will upload a hosted Sentinel report automatically.
197
+ - Preserves your existing reporter configuration
198
+ - Injects a Playwright JSON reporter if one is missing
199
+ - Sets sensible artifact defaults:
200
+ - trace: `retain-on-failure`
201
+ - screenshot: `only-on-failure`
202
+ - video: `retain-on-failure`
203
+ - Uploads the run to Sentinel at the end of the test run
192
204
 
193
205
  ## Options
194
206
 
@@ -203,19 +215,12 @@ withSentinel(config, {
203
215
  });
204
216
  ```
205
217
 
206
- ## Sentinel Cloud (optional)
218
+ ## Workspace
207
219
 
208
- Sentinel Cloud adds:
220
+ If you want private run history, recurring issue tracking, and team access, sign up for a Sentinel workspace and set `SENTINEL_TOKEN`.
209
221
 
210
- - hosted debugging dashboards
211
- - CI run history
212
- - AI-generated failure summaries
213
- - flaky test detection
214
- - shareable run links
215
- - longer retention
216
- - compare against previous runs
217
- - recurring failure history
218
- - richer fix suggestions and team workflows
222
+ ```bash
223
+ SENTINEL_TOKEN=your_project_ingest_token npx playwright test
224
+ ```
219
225
 
220
- Free for up to 100 CI runs per month.
221
- Create an account at [sentinelqa.com](https://sentinelqa.com).
226
+ Create a workspace at [sentinelqa.com/register](https://sentinelqa.com/register).