-
Notifications
You must be signed in to change notification settings - Fork 211
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
[Question] How everyone deals with a big amount of snapshots? #132
Comments
At Facebook we did something different, we didn't commit images to the repository. Instead, we automatically saved screenshots externally. Then when a screenshot changed, we would send out tasks. Most of the time screenshot changes would be intentional, not a regression, so this flow worked very well. I recently (i.e. I first started talking about it today) built https://screenshotbot.io that creates a similar workflow (it creates GitHub issues instead when images change). I've built integrations with the Android equivalent library (github.com/facebook/screenshot-tests-for-android, I was one of the original authors of that library). If somebody has an interest with helping me make this work for iOS I would love to build it out. |
Likely we will at some point provide some tools for this, though the linked above project seems decent (it doesn't support this library though, only the pointfree snapshotting tool). |
@alanzeino ooh, I sent a PR for the pointfree library, but isn't merged yet. I didn't send a PR for ios-snapshot-test-case because I saw the PRs here weren't actively reviewed back then. I'm happy to send a PR now. Screenshotbot is now open source too: https://github.com/screenshotbot/screenshotbot-oss. The PR I send wouldn't be specific to Screenshotbot, it would just provide the infrastructure required to be able to run snapshot tests without the tests failing when snapshots change (the equivalent of this PR on the pointfree library: pointfreeco/swift-snapshot-testing#423) |
We have something similar inside our fork of the library because we've built the same infrastructure that Facebook has, I'll try PR a few things back here. |
@alanzeino That would be awesome, thanks! |
@makadaw In our project, we are creating more-and-more screenshot tests → more reference images. We will move the reference images directory into a separate git repo and integrate that as a git submodule, so our main 'app repo' doesn't increase in size as we add more tests (or updated versions of the existing tests). |
With time amount of snapshot is only growing and git is not really good with binary artefacts.
With dropping iOS versions sometimes need to regenerate many of snapshots.
How folks, you are dealing with these issues?
The text was updated successfully, but these errors were encountered: