Skip to content

Commit

Permalink
fix(cypress): Prevent flaky visual tests by making cursor transparent…
Browse files Browse the repository at this point in the history
… for snapshot

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
  • Loading branch information
susnux committed Jul 19, 2023
1 parent a7d9687 commit 7f9f5ee
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cypress/visual/NcAppSidebar/NcAppSidebarMixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,11 @@ export default function(compact) {

it('Renders ' + fileName, () => {
cy.mount(NcAppSidebar, defaultOptions)
cy.get('.app-sidebar-header').compareSnapshot(fileName)
cy.get('.app-sidebar-header')
// Ensure cursor is not displayed to prevent flaky tests (flashing input cursor)
.invoke('css', 'caret-color', 'transparent')
// Compare to "golden" standard
.compareSnapshot(fileName)
})
})
})
Expand Down

0 comments on commit 7f9f5ee

Please sign in to comment.