You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi guys,
I tried to look into this guide #65 (and many similar ones on the internet) but still cannot resolve my issue.
Basically, I am writing performance test cases in Cypress for my website.
It launches from a third-party Amazon Cognito sign-in page.
So when I go to my website, at first it will redirect me to the Cognito sign-in page, and then after signing in, I will be redirected back to the home page of my website.
What I want to test is the performance metrics of different actions performed on my website. But no matter what, I have to go through the login process.
Here's the problem that I encounter:
If the current browser hasn't yet previously signed in to my site, and so there's no cache (relating to this site) being stored in the browser, when I go to the site, the Cognito page will have a button allowing me to sign-in through my organization's SSO.
But if the current browser already has been previously used to sign in to my site, and so there's cache storing the previous sign-in data, when I go to the site again, the Cognito page will look different. It will have a button allowing me to Continue to my site (ie. the button shows something like 'Continue with <my organization>'). After clicking on it, I need not to enter passwords from the SSO again, and I am directly signed in.
I understand that lighthouse() command in cypress-audit first performs whatever actions I would like to test against, and then opens a new tab in order to estimate the performance metrics, and finally the new tab closes and resumes the Cypress test. So I encounter the "Continue button" mentioned above in this step, in the new tab (that lighthouse() tries to open).
So my question here is:
On the new tab, my testing script could not proceed further, because there isn't any sign-in button appearing on the new tab opened by lighthouse(), but instead, there's a "Continue button".
So the lighthouse() command got stuck there, causing the metrics measured to be 0. (Kinda frustrating because it obviously does not pass any threshold.)
My workaround: manually click the "Continue button" whenever the test script encounters that page.
Is there any way to have lighthouse() command automate this step?
Thanks. Feel free to comment.
PS Since my codes are private, I am unfortunately unable to share in the community, but feel free to arrange meetings with me to review and solve it together.
Look forward to any solutions! 💯
The text was updated successfully, but these errors were encountered:
kmock930
changed the title
3rd party authentication scenario: lighthouse runs for the landing/login page and not the app itself
3rd party authentication scenario: lighthouse runs the login page on a separate new tab
Nov 26, 2023
Hi guys,
I tried to look into this guide #65 (and many similar ones on the internet) but still cannot resolve my issue.
Basically, I am writing performance test cases in Cypress for my website.
It launches from a third-party Amazon Cognito sign-in page.
So when I go to my website, at first it will redirect me to the Cognito sign-in page, and then after signing in, I will be redirected back to the home page of my website.
What I want to test is the performance metrics of different actions performed on my website. But no matter what, I have to go through the login process.
Here's the problem that I encounter:
<my organization>
'). After clicking on it, I need not to enter passwords from the SSO again, and I am directly signed in.So my question here is:
Thanks. Feel free to comment.
PS Since my codes are private, I am unfortunately unable to share in the community, but feel free to arrange meetings with me to review and solve it together.
Look forward to any solutions! 💯
The text was updated successfully, but these errors were encountered: