You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are 9 snapshots, it regenerates all of them and then deletes them.
In another case it would delete all 9, but then recreate 1 but in not in the __snapshots__ folder directly, but in a folder __snapshots__/test_filename where test_filename is the name of the test script. The snapshot itself had the correct filename.
To reproduce
Steps to reproduce the behavior:
Create tests with JSONSnapshotExtension
Run pytest --snapshot-update and commit
Rerun pytest --snapshot-update without actually having made any changes.
Get 9 snapshots generated. 9 unused snapshots deleted. and indeed all your snapshots deleted.
Expected behavior
Not deleting snapshots that are still being used.
Screenshots
Environment (please complete the following information):
OS: NixOS 22.11
Syrupy Version: 4.0.2
Python Version: 3.11.3
Additional context
The text was updated successfully, but these errors were encountered:
Describe the bug
I migrated from
AmberSnapshotExtension
toJSONSnapshotExtension
. Updating after the initial conversion I getThere are 9 snapshots, it regenerates all of them and then deletes them.
In another case it would delete all 9, but then recreate 1 but in not in the
__snapshots__
folder directly, but in a folder__snapshots__/test_filename
wheretest_filename
is the name of the test script. The snapshot itself had the correct filename.To reproduce
Steps to reproduce the behavior:
JSONSnapshotExtension
pytest --snapshot-update
and commitpytest --snapshot-update
without actually having made any changes.9 snapshots generated. 9 unused snapshots deleted.
and indeed all your snapshots deleted.Expected behavior
Not deleting snapshots that are still being used.
Screenshots
Environment (please complete the following information):
Additional context
The text was updated successfully, but these errors were encountered: