Not handling origin change when navigating via .back/.go #23736
Labels
E2E
Issue related to end-to-end testing
Triaged
Issue has been routed to backlog. This is not a commitment to have it prioritized by the team.
type: bug
type: unexpected behavior
User expected result, but got another
Current behavior
We are intercepting
.back()
or.go()
. to determine if the origin is changing before unloading the page. This means we are not collecting the current run state (i.e. test that ran, num passes/failed/pending, current reporter state) which in turn restarts the test from the very beginning.This is observed in our navigation tests (specifically this test). Running in open mode, and you will see it hit the test and then restart all of the tests from the top.
Desired behavior
Collect run state if we change origin: https://github.com/cypress-io/cypress/blob/develop/packages/driver/src/cy/commands/navigation.ts#L1165
Test code to reproduce
Run https://github.com/cypress-io/cypress/blob/develop/packages/driver/cypress/e2e/commands/navigation.cy.js#L768
Cypress Version
10.7.0
Node version
16.14.2
Operating System
Mac
Debug Logs
No response
Other
No response
The text was updated successfully, but these errors were encountered: