Skip to content

Screenshot file name too long warning when Bytes exceeded #2403

@rafaelcaviquioli

Description

@rafaelcaviquioli

Current behavior:

Currently I use BDD to document acceptance test cases, each test scenario is well detailed, Cypress uses the description of "it" to create the screenshot file name, but when "it" exceeds 255 characters it is not possible to create the screenshot file.

  6) As a quality manager, i would like to query the occurence history to find information about them GIVEN that im onthe search sreen, WHEN i fill in the ocurrence date fields, check the only delayed ones box and click on the filter button, THEN i see the filtered results:
     Error: ENAMETOOLONG: name too long, open '/home/node/cypress/screenshots/tools/us6.spec.js/As a quality manager iwould like to query the occurence history to find information about them -- GIVEN that im on the search sreen WHEN i fill in the ocurrence date fields check the only delayed ones box and click on the filter button THEN i see the filteredresults (failed).png'

Desired behavior:

  1. I hope Cypress allows me to change the name of the destination file from the screenshot before it writes it.
  2. Or, I hope Cypress will worry about the size of the file before it writes it and limits it to 255 characters.

Steps to reproduce:

  1. Create a test case with "it" description too long, bigger then 255 caracteres.
  2. Make a test case broken.
  3. Run tests.
  4. Look the verbose log, the screenshot not was created.

Versions

Cypress: 3.0.3
Browser: Chrome 67

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions