Skip to content

Conversation

@bedrich-schindler
Copy link
Contributor

No description provided.

bedrich-schindler and others added 14 commits September 2, 2025 10:19
I introduced Playwright Component Testing as replacement for Jest and RTL.

Those tests must be run within `playwright` docker container with pre-installed
browsers to ensure uniform testing environment. `.env.playwright` is created
using `postinstall` script to follow zero-config setup. `.env.playwright` can
be used to tweak parameters for local development if needed.

`.env` newly contains Playwright related configuration for Docker.

Currently, only tests for `Alert` and `Button` components are migrated to
Playwright CT as this commit is supposed to be proof-of-concept. Rest should
be migrated in later pull request.

All visual tests use prop tests concept we already have for Jest to simplify
testing and to make it DRY. `mixPropTests()` is introduced to mix those
to create combinations to be tested.

New Github workflow is introduced to test only Playwright as it can be
time exhausting. Further improvements are expected to be make in the future.
Transform Playwright related files to Typescript and introduce temporary
configuration files `.eslintrc-ts`, `jest.config-ts.js` and `tsconfig.json`
that must be removed when whole package is transformed into Playwright.

Due to missing TypeScript support in the rest of the package, `*.spec.tsx`
and `*.story.tsx` file do not have complete types and might not be compatible
with strict type checking that should be introduced in #394.

The reason for such change is parallel work on transformation to TypeScript
and on Playwright tests.
@bedrich-schindler bedrich-schindler merged commit 14b0f38 into master Sep 2, 2025
11 checks passed
@bedrich-schindler bedrich-schindler deleted the next branch September 2, 2025 09:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants