Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/antondomashnev/fbsnapshotsviewer
A mac os application that shows the failing snapshot tests from FBSnapshotTestCase
https://github.com/antondomashnev/fbsnapshotsviewer
snapshot-testing tool xcode
Last synced: 10 days ago
JSON representation
A mac os application that shows the failing snapshot tests from FBSnapshotTestCase
- Host: GitHub
- URL: https://github.com/antondomashnev/fbsnapshotsviewer
- Owner: Antondomashnev
- License: mit
- Created: 2017-02-05T12:00:53.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2022-10-05T20:26:32.000Z (about 2 years ago)
- Last Synced: 2024-10-09T23:10:57.558Z (27 days ago)
- Topics: snapshot-testing, tool, xcode
- Language: Swift
- Homepage:
- Size: 970 KB
- Stars: 224
- Watchers: 8
- Forks: 15
- Open Issues: 10
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# FBSnapshotsViewer
[![Build Status](https://travis-ci.org/Antondomashnev/FBSnapshotsViewer.svg?branch=master)](https://travis-ci.org/Antondomashnev/FBSnapshotsViewer)
[![codebeat badge](https://codebeat.co/badges/f21f5fd8-5b7e-4cec-bc3e-8ce719300ed7)](https://codebeat.co/projects/github-com-antondomashnev-fbsnapshotsviewer)
[![codecov](https://codecov.io/gh/Antondomashnev/FBSnapshotsViewer/branch/master/graph/badge.svg)](https://codecov.io/gh/Antondomashnev/FBSnapshotsViewer)A macOs application that shows the failing snapshot tests from [FBSnapshotTestCase](https://github.com/facebook/ios-snapshot-test-case) because it's a pain to parse the console logs by myself.
## Why FBSnapshotsViewer?
I've been using an amazing [plugin](https://github.com/orta/Snapshots) to check the failing test's snapshots, but unfortunately, with Xcode 8 the plugins are not officially supported anymore, so I've decided to build an app which will work regardless Apple's decisions about Xcode and plugins ecosystem.
There are some benefits using it:
* Real-time feedback about failed snapshot test.
* Real-time feedback about recorded snapshot test.
* Clear output with reference | diff | failed image
* Split and diff mode to see exact differences
* One click to use failed image as a recorded
* Xcode and AppCode support![Example](Resources/Example.png)
## How it works?
The idea behind the job is quite tricky, but the overall concept is straightforward:
1. The app listens for the changes in Xcode DerivedData folder;
2. When the app finds new .log file generated by Xcode it starts parsing it;
3. Through the parsing it extracts the generated information by iOS snapshot tests framework and shows in UI## Installation
### FBSnapshotsViewer application
At the moment there is only one option to install the app:
Navigate to [releases](https://github.com/Antondomashnev/FBSnapshotsViewer/releases) and download the latest `FBSnapshotsViewer-xyz.app.zip` release.We encourage you to turn automatic update on, so you'll be always up to date 🚀
## Usage
As simple as just run the app and run tests in your app 🎉
### App Code
For the AppCode support the app needs to know where is a folder with generated test logs:
Open `FBSnapshotsViewer` -> `Right click` -> `Preferences` -> Set derived data folder path as a path like `~/Library/Caches/AppCodeXYZ` where `XYZ` is an AppCode version. Usually you'll have only one such folder under the `Caches` directory.## Contribution
Contributions to FBSnapshotsViewer are welcomed and encouraged!
Please see the [Contributing guide](CONTRIBUTING.md) for more details.## License
FBSnapshotsViewer is available under the MIT license. See [LICENSE](LICENSE) for more information.