-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Open
Labels
existing workaroundprevent-stalemark an issue so it is ignored by stale[bot]mark an issue so it is ignored by stale[bot]topic: screenshots 📸topic: video 📹type: unexpected behaviorUser expected result, but got anotherUser expected result, but got another
Description
Current behavior
When we have a test folder structure like this:
cypress
--> specs
--> some-test.cy.js
--> some-folder
--> some-other-test.js
And screenshots are taken within the above tests, we get screenshots added the following way:
cypress
--> screenshots
--> screenshot-some-test
--> screenshot-some-other-test
Desired behavior
How it used to work and how all visual regression tools need it to work:
cypress
--> specs
--> some-test.cy.js
--> some-folder
--> some-other-test.js
And screenshots are taken within the above tests, we get screenshots added the following way:
cypress
--> screenshots
--> screenshot-some-test
--> some-folder
--> screenshot-some-other-test
If it's too much work to fix the above, can you please include specName back to the after:screenshot details object?
Cypress 9.x after:screenshot details object:
{
name: 'folder-structure-test/folder-structure-spec-wholePage',
specName: 'folder-structure-test/folder-structure-spec.js',
path: '/Users/filipporaimondi/code/cypress-image-diff/cypress/screenshots/folder-structure-test/folder-structure-spec.js/folder-structure-test/folder-structure-spec-wholePage (1).png',
...
}
Cypress 10.x after:screenshot details object:
{
name: 'folder-structure.cy-wholePage',
path: '/Users/filipporaimondi/code/cypress-image-diff/cypress/screenshots/folder-structure.cy-wholePage (1).png',
...
}
Test code to reproduce
Just take any screenshot within a folder structure above to replicate...
Cypress Version
10.x
Node version
16.x
Operating System
mac
Debug Logs
No response
Other
No response
andrewmcoupe, gabrielgagne, bjornlauwerijs, marcooop, CoreyGahafer and 15 more
Metadata
Metadata
Assignees
Labels
existing workaroundprevent-stalemark an issue so it is ignored by stale[bot]mark an issue so it is ignored by stale[bot]topic: screenshots 📸topic: video 📹type: unexpected behaviorUser expected result, but got anotherUser expected result, but got another