From 19c3b50c976bca96a045a0477492a1bdd3eb249b Mon Sep 17 00:00:00 2001 From: Matchu Date: Tue, 4 May 2021 13:49:53 -0700 Subject: [PATCH] Add attribution for Cypress window size hack --- cypress/plugins/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cypress/plugins/index.js b/cypress/plugins/index.js index c3f4d74..cd61764 100644 --- a/cypress/plugins/index.js +++ b/cypress/plugins/index.js @@ -16,6 +16,8 @@ module.exports = (on, config) => { // Our screenshots from `cypress-plugin-snapshots` are affected by the actual // window size, not just the viewport size! To avoid downscaling outfit // previews, try to open the window at 1000x800 at minimum. +// +// Adapted from https://github.com/meinaart/cypress-plugin-snapshots/issues/104#issuecomment-636463370 function ensureWindowSize(on) { const w = 1000; const h = 800;