-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Many Cypress tests are hanging at the first Visit command during full runs (Electron only) #3662
Comments
Could you provide the test code you are running? Also, are you sure that your application is indeed firing it's load event within this time? So, can you see if this is console.logging from your code? <script>
window.addEventListener("load", function(event) {
console.log("load event fired!");
});
</script> |
@jennifer-shehane : Test looks like this: var loadEvent = "not fired"
window.addEventListener("load", function(event) {
console.log("load event fired!");
loadEvent = "fired";
});
describe('Blah Blah Blah', function() {
it('More Blah Blah', function(){
var user = this.user; //User object
var pageInformation = this.pages.addressBook; //Page object
cy.log(loadEvent)
cy.visit(this.pages.home.url)
//There are more Cypress commands, but it gets stuck at the Visit above
})
}) I edited the post above, but it's worth noting that this hanging does not occur in when running in Chrome 72. And the loadEvent is coming back "fired" (I hope I inserted your script correctly). |
same experience for me. #2265 |
This looks to be a duplicate of #2938 I'm curious if blacklisting some hosts as laid out in this comment may help the |
FYI: I was able to fix this problem by blacklisting Google ad and tracking hosts. |
Current behavior:
In Electron, about one third of my tests are failing during a full run because it's hanging at the first Visit command (both headless and headed). Usually it's the same tests, but not always. When running alone, I do not experience this issue
Works correctly in Chrome 72.
Steps to reproduce: (app code and test code)
Running all tests. When it hangs, I get this error:
Your page did not fire its 'load' event within '60000ms'.
However, it looks like everything had loaded:
Let me know if there is any other debug information I can provide.
Versions
3.1.5
Electron 59
The text was updated successfully, but these errors were encountered: