Skip to content

v0.53.0

Choose a tag to compare

@PhenX PhenX released this 14 Oct 20:48
abf2b8a

This release records per-test browser and server coverage and ranks the changed lines the failing tests executed as suspect lines, shows the page's live state in the DOM view, marks retried attempts on the run timeline, and adds a sample app that ASP.NET Core and Nitro both serve.

Full diff: v0.52.0…v0.53.0

✨ Highlights

  • 🎯 Suspect lines — From per-test browser and server coverage, Piwi ranks the changed lines the failing tests executed, reads them against the file at the head commit, and shows them on the failure pages and in the cluster's diff.
  • 🧪 Per-test server coverage — The ASP.NET Core instrumentation records each test's server code coverage, and the reporter sends it with the test.
  • 🖱️ Live page state in the DOM view — The reporter captures focus, hover and selection at test end, and the DOM view shows the page's values, dialogs, focus, hover and the mouse.
  • 🔁 Retries on the run timeline — The run timeline shows which failed attempts were retried and links a test's attempts.
  • 🧱 One sample app for every backend — A sample app served by ASP.NET Core and Nitro replaces the Nitro example, and a Nitro module lists every route in the route manifest at build time.

Features

Coverage & suspect lines

  • record per-test browser and server coverage, and rank suspect lines (7d9a429)
  • reporter: add the coverage model and its wire shapes to @piwitests/core (9a7b29b)
  • db: store per-test coverage, run coverage and code reach per runtime (81fc74c)
  • record per-test server code coverage in the ASP.NET Core instrumentation (ad86808)
  • reporter: collect each test's server coverage and send it with the test (990230b)
  • ai: rank the changed lines the failing tests executed as suspect lines (3a0284b)
  • ai: read suspect lines against the file version at the head commit (7c528d2)
  • ui: show suspect lines on the failure pages and mark them in the cluster's diff (675ebd7)
  • app: show line-level suspect lines in the demo, from an ASP.NET Core API file (5fd51b4, 1b27c0b)

DOM view & the run timeline

  • reporter: capture focus, hover and selection at test end (b7a5cde)
  • app: show the page's live state (values, dialogs, focus, hover) in the DOM view (9005636)
  • app: render the page's recorded live state in the DOM view (f356181)
  • app: show the mouse and what it hovered in the DOM view (8ba8cb6)
  • app: show which failed attempts were retried on the run timeline, and link a test's attempts (7f059ca, 8216a1c)

Sample app & backends

  • add a sample app every supported backend serves, with ASP.NET Core first (0afde3b)
  • serve the sample app from Nitro too, and retire the Nitro example (6ecc377)
  • list every Nitro route in the route manifest, read at build time by a Nitro module (177220b)

Performance Improvements

  • reporter: read code reach from V8 function coverage through a CDP session (767fbec)

Bug Fixes

Coverage & suspect lines

  • ai: fix what the review of suspect lines found (eba7ba8)
  • reporter: give coverage the blob id git stores, after its line ending filters (9bc9645)
  • recompile when switching between a coverage build and a plain build (ca8b80a)
  • place a backend's source files when it runs outside its repository (d76f10d)

Screenshots & requests

  • app: show a screenshot at the failure only when it is the failing page's, not the first one (36eabfa, 2cec8b7)
  • reporter: screenshot the page a failed test was on (b799e80)
  • reporter: keep a request whose response arrived but whose body the page never read (b87a8a8)

Integrations

  • load the Nitro integration's build in Node, and name a route by its h3 1.x pattern (82b8c17)
  • record an unhandled exception on the X-Piwi-Logs of its 500 response (202e89d)