shadow icon indicating copy to clipboard operation
shadow copied to clipboard

Reftest or go home

Open CanadaHonk opened this issue 2 years ago • 0 comments

My hope for tests is just™ "simply" reftest real (simple) sites instead of creating our own tests. Eg, we have test/reftest/example.com.png and a runner which somehow opens a headless browser[^1] running a local copy of Shadow, which saves an image from the canvas and compares it to the local expected image file.

Theoretically the runner just has to:

  1. Open Shadow in browser with URL via /?...
  2. Wait ?s for load and to stabilize
  3. Get an image from the canvas (hopefully not using WD[^2] image/screenshot)
  4. Compare to expected

We could even make this runner run in the browser itself instead of using WD[^2] (or some library), but 0 clue how we could automate that with a local runner or even CI.

[^1]: this feels like it will be painful to CI un-flakily [^2]: WD = WebDriver

CanadaHonk avatar Nov 09 '23 00:11 CanadaHonk