-
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
Using apollo-client breaks the tests when run with electron #5044
Comments
Same issue here. describe('test name', () => {
before(() => {
cy.login()
})
beforeEach(() => cy.visit('/create'))
it('first case', () => {
cy.get(saveButton)
.parent()
.should('be.disabled')
})
// starts to fail
it('second case', () => {
cy.get(collectionNameInput).then($element => {
cy.wrap($element).type('Collection name')
})
cy.get(saveButton).then($saveButton => {
cy.wrap($saveButton)
.parent()
.should('be.enabled')
})
})``` |
I can also reproduce this by running the example repo in Chrome 61, leading me to think it's a bug between Cypress, the bundled Chrome version (61), and #4720 should fix this issue by upgrading the bundled Chrome to a modern version. |
The code for this is done in cypress-io/cypress#4720, but has yet to be released. |
1 similar comment
The code for this is done in cypress-io/cypress#4720, but has yet to be released. |
Super psyched to see this update! I'd be happy to test a pre-release version 😃 Thank you @nik-lampe for reporting the issue and building a reproduction! |
@justinanastos here's a link with instructions to download the latest prerelease: c141603#commitcomment-35551163 |
Released in |
Current behavior:
I have an app that uses apollo for graphql queries. Then I wrote a test, that simply checks if all the links in my app work as expected.
This works fine when run in chrome, but when run in electron every other test fails with an
Uncaught Invariant Violation: Maximum update depth exceeded
error.Desired behavior:
Well... this should not happen, i guess :)
Steps to reproduce: (app code and test code)
I have stumbled across this in my production app, but I have recreated it with a minimal setup.
You can see it in action here:
https://github.com/nik-lampe/cypress-apollo-maximum-stack-error
It's just the sample app from apollo from here:
https://codesandbox.io/s/r5qp83z0yq
Together with a really simple test:
Just run yarn, run the app with yarn start, and then run the test runner. Choose electron, and it fails. Use chrome and it's green.
Versions
{
"@apollo/react-hooks": "0.1.0-beta.11",
"apollo-boost": "0.4.3",
"cypress": "^3.4.1",
"graphql": "latest",
"react": "16.8.6",
"react-art": "16.3.2",
"react-dom": "16.8.6",
"react-native-web": "latest",
"react-router": "latest",
"react-router-dom": "latest",
"react-scripts": "1.1.0",
"recyclerlistview": "1.2.6"
}
MacOS Mojave 10.14.6
The text was updated successfully, but these errors were encountered: