Has anyone used Cypress to perform UI functional testing in AEM sites? | Community
Skip to main content
Level 2
September 8, 2021
Solved

Has anyone used Cypress to perform UI functional testing in AEM sites?

  • September 8, 2021
  • 2 replies
  • 5183 views

We are planning to Cypress instead of Selenium webdriver to do UI functionality testing in AEM sites. Wondering whether anyone has used it in their projects. Would be good if you can please share your insights with me. Thanks in advance.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Ritesh21

Can you please refer me to those workarounds, especially for multiple tabs. I have tried to use stubs, but was not successful. This is the code I have

 

 

const editWindowUrl = <yourUrl> cy.window().then((win) => { const stub = cy.stub(win, "open").as("windowOpen"); }); cy.contains("Edit").click(); cy.get("@windowOpen").should("be.called"); cy.window().then((win) => { win.location.href = editWindowUrl; });

 

 

Thanks in advance. 

2 replies

September 8, 2021

We currently using Cypress for UI Functional Automation for AEM sites and it is working fine.

iframe and multiple tab functionality wont work and but we can do workaround for that.

Ritesh21Accepted solution
September 15, 2021

Can you please refer me to those workarounds, especially for multiple tabs. I have tried to use stubs, but was not successful. This is the code I have

 

 

const editWindowUrl = <yourUrl> cy.window().then((win) => { const stub = cy.stub(win, "open").as("windowOpen"); }); cy.contains("Edit").click(); cy.get("@windowOpen").should("be.called"); cy.window().then((win) => { win.location.href = editWindowUrl; });

 

 

Thanks in advance. 

kautuk_sahni
Community Manager
Community Manager
September 21, 2021

@ritesh21 , Thank. you for sharing the solution with AEM community. Looking forward to more contribution from you here. Great to have AEM SMEs like you here. Keep it up

Kautuk Sahni
Level 2
June 20, 2022

We are using cypress for end user automation testing which works fine, however as part of the platform we are building I want to also have a set of editorial automation tests, however with AEMaaCS we are struggling to get past the cloudmanager SSO login.

 

Has anyone done an AEMaaCS editorial test using cypress that should how to get past the SSO login,

September 29, 2023

yes, in CS , instead of SSO login use ims jwt token