Skip to content

Add visual coverage of library components #76

Description

@microbit-matt-hillsdon

The approach needs discussion.

Lessons from the app harnesses

Playwright-based implementations from the migration in git: ml-trainer 043e5bd1, python-editor
f322b68e.

  • Determinism requires stubbing in-page randomness via
    context.addInitScript: seed Math.random, and make
    crypto.getRandomValues/randomUUID write a monotonic per-call prefix so
    generated-id sort order matches creation order under load.
  • Use the reducedMotion context option to pause CSS animations.
  • expect.soft for screenshots so one diff doesn't hide later states.
  • Keep image baselines off CI-gating unless running in a pinned browser
    container — they are font-rendering sensitive.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions