Add test-runner to Storybook and script to run locally

What does this MR do and why?

  1. Extends Storybook with test-runner and axe-playwright, using the same configuration as in GitLabUI
  2. Adds storybook:dev:test script for running the tests locally
  3. Saves results in a json file

References

Screenshots or screen recordings

Before After
n/a Screenshot_2025-07-09_at_19.59.55
n/a Screenshot_2025-07-09_at_20.15.10
n/a Screenshot_2025-07-22_at_11.06.01

How to set up and validate locally

  1. Checkout the branch
  2. Run yarn install in the root and storybook directory
  3. Run storybook:start or storybook:start:skip-fixtures-update. Keep it running. The Storybook needs to be built for the tests to run.
  4. Run storybook:dev:test from the root directory

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #507448 (closed)

Edited by Paulina Sedlak-Jakubowska

Merge request reports

Loading