-
-
Notifications
You must be signed in to change notification settings - Fork 92
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
obsolete snaps not deleted #130
Comments
I ran into this issue earlier today---I was considering either:
Thoughts? |
Another example is Jest which deletes the obsolete tests when it's passed an update flag, pretty much Seems Jest determines obsolete snaps by first reading the all the snapshots in the directory and then checking off whether it was actually used when evaluating the tests: |
To the extent you're familiar with Jest, do you know how it evaluates whether the full test suite is being run, rather than a subset? |
sorry I'm not really familiar of jest's inner workings But I get what you're saying: how does jest avoid deleting snapshots for tests that weren't run |
Jest controls the entire test harness---it knows which tests are running and which aren't, because Jest is the thing running the tests. Is there a way to replicate this in |
I toyed around with this earlier and I couldn't find a good way to deal with running only a subset of tests unfortunately. |
Going to close this for now. While still not perfect, at least you can hack it together now: #136 |
Currently when moving files around the old snapshots with the old filenames aren't deleted.
reproduce
foo.rs
bar.rs
bar.rs
The text was updated successfully, but these errors were encountered: