Skip to content

Conversation

@davidmunechika
Copy link
Contributor

@davidmunechika davidmunechika commented Sep 28, 2021

User facing changelog

Users can pass overwrite: true as an option to cy.screenshot() to overwrite existing screenshots with the same file name.

Additional details

When overwrite is false (by default), the screenshots append a number at the end of each screenshot taken with the same name as an existing screenshot.

  • test name.png
  • test name (1).png
  • test name (2).png

When overwrite is set to true, the new screenshot will overwrite an existing screenshot with the same file name.

PR Tasks

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Sep 28, 2021

Thanks for taking the time to open a PR!

@cypress
Copy link

cypress bot commented Sep 28, 2021



Test summary

18536 0 214 7Flakiness 1


Run details

Project cypress
Status Passed
Commit 7a3358e
Started Sep 30, 2021 3:06 PM
Ended Sep 30, 2021 3:17 PM
Duration 11:08 💡
OS Linux Debian - 10.9
Browser Multiple

View run in Cypress Dashboard ➡️


Flakiness

cypress/integration/commands/net_stubbing_spec.ts Flakiness
1 network stubbing > waiting and aliasing > can timeout waiting on a single request using "alias.request"

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@davidmunechika davidmunechika marked this pull request as ready for review September 29, 2021 15:23
@davidmunechika davidmunechika requested a review from a team as a code owner September 29, 2021 15:23
@davidmunechika davidmunechika requested review from chrisbreiding and flotwig and removed request for a team September 29, 2021 15:23
Copy link
Contributor

@flotwig flotwig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good, but I think the test could be stricter

flotwig
flotwig previously approved these changes Sep 30, 2021
Copy link
Contributor

@flotwig flotwig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great!

Copy link
Contributor

@chrisbreiding chrisbreiding left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just requested a couple small changes, but otherwise looks great.

Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
@chrisbreiding chrisbreiding merged commit 0e7d882 into develop Sep 30, 2021
@davidmunechika davidmunechika deleted the issue-7955-overwrite-existing-screenshots branch September 30, 2021 15:34
tgriesser added a commit that referenced this pull request Oct 8, 2021
* develop: (31 commits)
  fix: `everyNthFrame` should only be applied for Chrome 89+ (#18392)
  docs: General updates to contributing guide (#18283)
  chore: Update Chrome (beta) to 95.0.4638.40 (#18389)
  chore: use circleci timings split for e2e tests (#18367)
  fix: fixed title (#18370)
  chore(deps): update dependency electron to v14 🌟 (#18384)
  chore(server): share client route (#18215)
  fix: Prevent Cypress from crashing when argument parsing "spec: {}" (#18312)
  chore: update husky dev dependency to v7 (#18345)
  feat: add defineConfig function to help type config (#18302)
  chore: Update Chrome (stable) to 94.0.4606.71 (#18324)
  feat: allow to use TypeScript in the config file (#18300)
  allow select to be called with empty array (#18329)
  fix(vite-dev-server): windows `supportFile` + preserve optimize entries (#18286)
  chore: fix semantic-release dry run (#18332)
  fix(driver): improve status_code_flags_invalid error message (#18316)
  chore(deps): update dependency electron to v13.5.0 🌟 (#18318)
  chore: Update Chrome (stable) to 94.0.4606.61 and Chrome (beta) to 95.0.4638.32 (#18229)
  fix(proxy-logging): use constant consoleProps object (#18207)
  feat(driver): Add "overwrite" option to cy.screenshot() (#18280)
  ...
mjhenkes pushed a commit that referenced this pull request Jul 27, 2022
Co-authored-by: Zach Bloomquist <github@chary.us>
Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add "overwrite" Option to cy.screenshot()

4 participants