diff --git a/packages/driver/src/cy/commands/window.js b/packages/driver/src/cy/commands/window.js index 8b838e9473f8..cce0416702df 100644 --- a/packages/driver/src/cy/commands/window.js +++ b/packages/driver/src/cy/commands/window.js @@ -41,9 +41,9 @@ module.exports = (Commands, Cypress, cy, state) => { // need to restore prior to running the next test // after which we simply null and wait for the // next viewport change - const testDefaultViewport = _.pick(Cypress.config(), 'viewportWidth', 'viewportHeight') + const configDefaultViewport = _.pick(Cypress.config(), 'viewportWidth', 'viewportHeight') - setViewportAndSynchronize(testDefaultViewport.viewportWidth, testDefaultViewport.viewportHeight) + setViewportAndSynchronize(configDefaultViewport.viewportWidth, configDefaultViewport.viewportHeight) }) const setViewportAndSynchronize = (width, height) => {