Skip to content

Are there any way to force plugin to make screenshots of the same size in headed/headless browsers? #159

Answered by FRSgit
viktorgogulenko asked this question in Q&A
Discussion options

You must be logged in to vote

Hello again @viktorgogulenko,

There are 3 (ish) solutions to this problem:

  • First of all, this plugin tried to scale the images based on your devicePixelDensity (if it can be properly obtained, of course) - maybe consider filing a bug report with reproduction scenario (I recommend starting off the example directory),
  • Your can try to always force the same window size: cypress-io/cypress#3324 (comment),
  • and the 3rd(ish) solution - do not make screenshots in headed mode - see official cypress guidelines about that. In my projects I specify different imageDir path for headed run. So, the screenshots made in headless mode are compared with others done in headless mode and ones made in headed m…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@viktorgogulenko
Comment options

@FRSgit
Comment options

Answer selected by viktorgogulenko
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants