Open vegerot opened 3 years ago
Looking into this more, it gets even weirder. It looks like this bug only happens the FIRST time you open cypress...sometimes.
If I have a line like
cy.document().toMatchImageSnapshot({ capture: 'runner' });
Then about 50% of the time it will use fullScreen
, and the other 50% it will use viewport
. I still cannot get runner
to work.
I'm not totally sure, but I think I figured it out (mostly).
Looks like
cy.document().toMatchImageSnapshot({ screenshotConfig: { capture: 'runner' } });
works.
Related to #152 and #153
Related to those, please update the types because
Describe the bug When running
the option I provide to
capture
does nothing. It will always use thefullScreen
setting, no matter what I do.To Reproduce Steps to reproduce the behavior:
toMatchImageSnapshot
testcapture
settingExpected behavior It should respect the
capture
settingDesktop (please complete the following information):
Additional context
Another way to show this is to do something like
As you start changing the
capture
settings to bothscreenshot
andtoMatchImageSnapshot
, you'll see that thescreenshot
will update the image to look very different each time, buttoMatchImageSnapshot
looks identical