Skip to content

Commit

Permalink
fix: fixed screenshot comparison e2e authcode/avatar (#41)
Browse files Browse the repository at this point in the history
* fix: fixed screenshot comparison e2e authcode

This test was failing due the click, keep the mouse on the top of the input. Triggering hover state.

With old tolerance this was ok, right now it fail the test.

* fixed also avatar failing test
  • Loading branch information
salvatorecriscioneweb authored Dec 22, 2023
1 parent a857491 commit c631a05
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions docs/e2e/authcode.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,7 @@ test("Default: should change focus when the user finish the input", async ({

test("Password: should not print any character", async ({ page }) => {
await page.getByLabel("Character 1").click();
await page.mouse.move(0, 0); // Remove the mouse from the input, to avoid hover state
await page.getByLabel("Character 1").fill("1");
await page.getByLabel("Character 2").fill("1");
await page.getByLabel("Character 3").fill("1");
Expand Down
2 changes: 1 addition & 1 deletion docs/e2e/avatar.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ test("Sizes: should render and match screenshot", async ({ page }) => {
});

test("ActiveStatus: should render and match screenshot", async ({ page }) => {
await expect(page).toHaveScreenshot(`${COMPONENT_NAME}-Sizes.png`, {
await expect(page).toHaveScreenshot(`${COMPONENT_NAME}-ActiveStatus.png`, {
maxDiffPixelRatio: PLAYWRIGHT_MAX_DIFF_PIXEL_RATIO,
});
});
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit c631a05

Please sign in to comment.