Skip to content

Commit

Permalink
Revert "fix: revert playwright bug workaround"
Browse files Browse the repository at this point in the history
This reverts commit 589e944.
  • Loading branch information
nmerget committed Dec 11, 2024
1 parent 37e685b commit 7f1649a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ const testA11y = () => {
test('should have same aria-snapshot', async ({ mount }, testInfo) => {
const component = await mount(comp);
const snapshot = await component.ariaSnapshot();
expect(snapshot).toMatchSnapshot(`${testInfo.testId}.yaml`);
// Some wired issue with react and playwright ariaSnapshot in this case
const playwrightReactIssueFix = snapshot.replace(': on', '');
expect(playwrightReactIssueFix).toMatchSnapshot(
`${testInfo.testId}.yaml`
);
});
test('should not have A11y issues', async ({ page, mount }) => {
await mount(comp);
Expand Down
6 changes: 5 additions & 1 deletion packages/components/src/components/radio/radio.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@ const testA11y = () => {
test('should have same aria-snapshot', async ({ mount }, testInfo) => {
const component = await mount(comp);
const snapshot = await component.ariaSnapshot();
expect(snapshot).toMatchSnapshot(`${testInfo.testId}.yaml`);
// Some wired issue with react and playwright ariaSnapshot in this case
const playwrightReactIssueFix = snapshot.replace(': on', '');
expect(playwrightReactIssueFix).toMatchSnapshot(
`${testInfo.testId}.yaml`
);
});
test('should not have A11y issues', async ({ page, mount }) => {
await mount(comp);
Expand Down

0 comments on commit 7f1649a

Please sign in to comment.