From bffe6e7c69e18b69d0d53431903f6577285f4bb0 Mon Sep 17 00:00:00 2001 From: Bill Glesias Date: Fri, 13 May 2022 17:03:53 -0400 Subject: [PATCH] revert this commit --- packages/driver/cypress/plugins/index.js | 14 ++++++++++++++ system-tests/projects/e2e/cypress/plugins/index.js | 2 ++ 2 files changed, 16 insertions(+) diff --git a/packages/driver/cypress/plugins/index.js b/packages/driver/cypress/plugins/index.js index c766dba708fa..e2748a990fe3 100644 --- a/packages/driver/cypress/plugins/index.js +++ b/packages/driver/cypress/plugins/index.js @@ -63,6 +63,20 @@ module.exports = (on, config) => { return null }, 'check:screenshot:size' ({ name, width, height, devicePixelRatio }) { + console.log('expected screenshot path', path.join(__dirname, '..', 'screenshots', name)) + console.log('screenshotfolder', config?.screenshotsFolder) + fs.readdirSync(config?.screenshotsFolder).forEach((file) => { + console.log(file) + }) + + console.log('done listing dirs') + + fs.readdirSync(path.join(config?.screenshotsFolder, 'e2e')).forEach((file) => { + console.log(file) + }) + + console.log('done listing screenshots') + return Jimp.read(path.join(__dirname, '..', 'screenshots', name)) .then((image) => { width = width * devicePixelRatio diff --git a/system-tests/projects/e2e/cypress/plugins/index.js b/system-tests/projects/e2e/cypress/plugins/index.js index 827a05a6c382..9122c73fb230 100644 --- a/system-tests/projects/e2e/cypress/plugins/index.js +++ b/system-tests/projects/e2e/cypress/plugins/index.js @@ -151,6 +151,8 @@ module.exports = (on, config) => { }, 'check:screenshot:size' ({ name, width, height, devicePixelRatio }) { + console.log('expected screenshot path', path.join(__dirname, '..', 'screenshots', name)) + return Jimp.read(path.join(__dirname, '..', 'screenshots', name)) .then((image) => { width = width * devicePixelRatio