-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Screenshot path does not corresponds to the spec path #22159
Comments
Hi, thanks for reporting this. I believe this is an unavoidable side effect of the change in Cypress 10 from setting an
|
Sorry for the late answer, but wouldn't such a behavior be bad if cypress was used for Visual Regression tests? If my Visual Regression tests are distributed into folders, running the tests under one of these folders will have unexpected results UpdateI think I can use |
@odai-alali |
Hello, I understand the idea to get rid of the ancestry folders. |
Hi, is there any news how it will be resolved? There is possibility to introduce some option to ignore stripping the common ancestor paths? |
+1 for adding an option to ignore stripping the common ancestor paths |
I have the exact same problem now after upgrading to v10+. I would like to understand if anyone was able to work around this issue using |
@VaibhavP17 you can use https://github.com/jaredpalmer/cypress-image-snapshot as an example how to setup screenshot behaviour |
@mateuszwrobel : In fact, I am using the same plugin in my project. But I am encountering the folder structure issue when I migrate to Cypress 10+ version. Can you please guide me to the modified version of |
@VaibhavP17 jaredpalmer/cypress-image-snapshot@f621ff6 or just can use their package: https://github.com/simonsmith/cypress-image-snapshot |
Thanks for the help @mateuszwrobel :) |
Duplicate of #24052 |
Current behavior
I have two spec files, each contains a simple test case where I take a screenshot with
cy.screenshot()
. Both screenshots will be saved directly underscressnshots
directory.Desired behavior
Screenshot from
cypress/e2e/deep/deep-example.cy.js
to be saved undercypress/screenshots/deep/deep example --passes.png
Test code to reproduce
https://github.com/odai-alali/cypress-screenshot-issue
Cypress Version
10.0.3
Other
No response
The text was updated successfully, but these errors were encountered: