Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Fix: flaky percy test "Rendering permalinks" (#10874)
Browse files Browse the repository at this point in the history
* hide timestamp

* retrigger sonar

* trigger build

* hide elements instead of removing them which might effect scroll

* lint
  • Loading branch information
Kerry committed May 19, 2023
1 parent 55336bf commit 8513d2f
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions cypress/e2e/permalinks/permalinks.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,13 +126,14 @@ describe("permalinks", () => {
getPill(danielle.getSafeUserId());
});

// clean up before taking the snapshot
cy.get(".mx_cryptoEvent").invoke("remove");
cy.get(".mx_NewRoomIntro").invoke("remove");
cy.get(".mx_GenericEventListSummary").invoke("remove");

// Disabled because flaky - see https://github.com/vector-im/element-web/issues/25283
//const percyCSS = ".mx_MessageTimestamp, .mx_MessagePanel_myReadMarker { visibility: hidden !important; }";
//cy.get(".mx_RoomView_timeline").percySnapshotElement("Permalink rendering", { percyCSS });
// Exclude various components from the snapshot, for consistency
const percyCSS =
".mx_cryptoEvent, " +
".mx_NewRoomIntro, " +
".mx_MessageTimestamp, " +
".mx_RoomView_myReadMarker, " +
".mx_GenericEventListSummary { visibility: hidden !important; }";

cy.get(".mx_RoomView_timeline").percySnapshotElement("Permalink rendering", { percyCSS });
});
});

0 comments on commit 8513d2f

Please sign in to comment.