Skip to content

Commit

Permalink
test: delete wait
Browse files Browse the repository at this point in the history
  • Loading branch information
hyesungoh committed Nov 12, 2023
1 parent d46b50a commit a0144cd
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions apps/blog/cypress/e2e/root/scroll-restoration.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,14 @@ describe('root - store restoration', { testIsolation: false }, () => {
it('should restore scroll position when go back', () => {
const SCROLL_Y_POSITION = 30;

cy.intercept('/').as('visitHome');
cy.visit('/');
cy.wait('@visitHome');

cy.window().then($window => {
$window.scrollTo(0, SCROLL_Y_POSITION);
});

cy.get('main').find('a').first().click();
cy.wait(3000);

cy.go('back');
cy.wait(3000);
cy.go('back', { timeout: 10000 });

cy.window().its('scrollY').should('not.eq', 0);
});
Expand Down

0 comments on commit a0144cd

Please sign in to comment.