Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
495 views
in Technique[技术] by (71.8m points)

security - Cypress issue with connection to the site is not secure?

I'm testing the website which have request to optimizely api to do some checking.

It request to url like https://cdn.optimizely.com/datafiles/XXX.json I suppose that this site required secure network.

I tried to open the url in cypress chrome and I get this error This page isn’t workingcdn.optimizely.com didn’t send any data. ERR_EMPTY_RESPONSE

enter image description here

But when I tried with the same network in chrome, I get fine response.

enter image description here

I need to be able to load the url to test my site.

Is there any solution to this matter. Please advice.

question from:https://stackoverflow.com/questions/65913996/cypress-issue-with-connection-to-the-site-is-not-secure

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

The resource returns 403 status code, that most likely indicates you don't have sufficient rights to see it:

enter image description here

Your Chrome outside Cypress runs might be set up differently, might already have session cookies.

You most likely need to figure out how to log into some account on the site throught Cypress.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...