Closed
Description
Current behavior:
When running cypress in GUI mode with numTestsKeptInMemory
set to 0
, snapshotting still occurs even though none of them should be kept in memory. This has a negative impact on performance and memory consumption.
In this screenshot, you can see that numTestsKeptInMemory
is 0
, but 5 seconds is spent taking snapshots that will not be used.
In this screenshot you can see where the majority of the snapshot execution took place, 3.4s converting rules from large stylesheets into a string, and 0.4s replacing URLs in those strings with absolute paths.
Desired behavior:
When running with numTestsKeptInMemory
set to 0
, snapshotting should be avoided in the same way that occurs while running in headless mode.
Steps to reproduce:
- Set
numTestsKeptInMemory
to0
. - Run cypress GUI mode.
Versions
Cypress: 3.2.0
Chrome: Chrome 74
Metadata
Metadata
Assignees
Labels
No labels
Activity
jennifer-shehane commentedon May 3, 2019
Hey @CoryDanielson, can you take a look at your resolved configuration and confirm that the
numTestsKeptInMemory
configuration is being read as set to0
? https://on.cypress.io/configuration#Resolved-ConfigurationCoryDanielson commentedon May 3, 2019
@jennifer-shehane I updated the original post with new screenshots.
CoryDanielson commentedon May 3, 2019
I opened up a PR to address this #4123
I extended the if statement to include a check for
numTestsKeptInMemory
brian-mann commentedon May 17, 2019
I'll take this PR from here and we'll get it out in the next patch release or so.
9 remaining items