Releases: pointfreeco/swift-snapshot-testing
1.8.2
- Rename
SnapshotTesting.record
toSnapshotTesting.isRecording
to avoid clash with XCTestCase's newrecord
method (thanks @xavierLowmiller). - Fix UIApplication selector to return the application as expected (thanks @mstultz).
- Fix key window warning (thanks @tinder-maxwellelliott)
1.8.1
- Change minimum iOS version from iOS 10 to 11 to fix SwiftUI linking problems (thanks @thedavidharris).
1.8.0
- Added: SwiftUI support (thanks @natemann, @regexident).
- Added: Apple TV 4K support (thanks @reez).
- Added: Mac Catalyst support (thanks @rjchatfield).
- Added: UIBezierPath, NSBezierPath, CGPath strategies (thanks @regexident).
- Improved: don't crash on empty images, instead produce error artifact (thanks @mackoj).
- Bug fixed: trait collection now passed to view controller's recursive description strategy (thanks @erikpoort).
- Bug fixed: will no longer crash on hidden/unloaded web views (thanks @stuaustin).
- Bug fixed: don't re-add view controller to window when already added (thanks @hassfers).
- More test coverage (thanks @SatoTakeshiX, @sidepelican).
- Typos fixed (thanks @freak4pc, @jstart).
- Other improvements: timeout error messaging, installation instructions, troubleshooting instructions, Linux CI.
Xcode 11.4 Support
This release fixes a bug introduced in the Xcode 11.4 beta with SPM and Swift 5.2.
SwiftPM Tools 5.0 Support
This minor release introduces backwards compatibility for SwiftPM Tools @ 5.0.
1.7.0
What's new?
- New snapshot strategy:
wait
(#268)
What's improved?
- Performance improvement: don't diff during recording (#250)
- Documentation improvement: Xcode 11 installation instructions (#256)
- NSView rendering improvements (#260)
- Documentation improvement: SPM test dependency instructions (#265)
- cURL rendering improvements (#273)
Thanks to @mr-v, @f-meloni, @schwmi, @freak4pc, and @ldstreet for contributing to this release!
1.6.0: Bug fixes and performance improvements 😆
What's changed since last time?
- Add device sizes for split view variants of iPads (#209)
- Add recording to inline snapshotting (#212)
- Sort cURL strategy headers (#214)
- Add iOS minimum required deployment target to Package.swift (#215)
- Allow dynamic size of views based on trait collection content sizes (#217)
- Disable bitcode (#221)
- Improve
_assertInlineSnapshot
ergonomics and tests (#231 and #232) - Use
URL.init(fileURLWithPath:isDirectory:)
to avoid file IO (#236) - Speed up image diffing (#248)
- Improve image diff drawing performance (#249)
Thanks to @Sherlouk, @crayment, @jayhickey, @MarianaMeireles, @pavel-y-ivanov, @ferranpujolcamins, @kirillyakimovich, and @mr-v for making this release happen!
Inline snapshots and more strategies
What's new
-
@rjchatfield has introduced (#199) a brand new way of snapshotting textual information, called "inline snapshot testing," which automatically inlines snapshots directly in your test file. The 1.5.0 release includes a preview of this functionality! You can use the
_assertInlineSnapshot
helper to try it out. Thanks to @rjchatfield for the PR, and find out more here. -
Two new
URLRequest
snapshot strategies have been included. First, @Sherlouk has included acurl
snapshotting strategy (#203), which snapshots your prepared requests in the cURL format. Also we now have a snapshot strategy for capturing aURLRequest
with its body pretty printed, when possible (#157). This helps makePOST
requests more easily inspectable in the reference file.
Swift 5 Support
This release brings SnapshotTesting up to date with Swift 5!
What's changed?
11" iPad Pro Support, Better Extensibility, Better Messaging
What's new?
- A new view configuration for the 11" iPad Pro's resolution and safe area (#187).
- A few
let
properties onSnapshotting
andDiffing
have been relaxed to bevar
s to make it easier to build strategies from existing ones (#189). - The UIImage diff message has been generalized to read nicely while in record mode (#188).