mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
Fix? flaky cypress by waiting for <no-ssr> content
Content menu is a client-side rendered component. Maybe an extra assertion will wait for it? That's how you can flix flaky cucumbers if you use capybara.
This commit is contained in:
parent
6cd8a4ef21
commit
4f7d5ee24f
@ -52,10 +52,11 @@ When('I click on "Report Post" from the content menu of the post', () => {
|
|||||||
When(
|
When(
|
||||||
'I click on "Report User" from the content menu in the user info box',
|
'I click on "Report User" from the content menu in the user info box',
|
||||||
() => {
|
() => {
|
||||||
cy.contains('.ds-card', davidIrvingName)
|
// wait client-side-rendered content
|
||||||
.find('.content-menu-trigger')
|
cy.get('.ds-card-content .content-menu button').should('exist')
|
||||||
.first()
|
|
||||||
.click({force: true})
|
cy.contains('.ds-card-content', davidIrvingName)
|
||||||
|
.find('.content-menu button').click()
|
||||||
|
|
||||||
cy.get('.popover .ds-menu-item-link')
|
cy.get('.popover .ds-menu-item-link')
|
||||||
.contains('Report User')
|
.contains('Report User')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user