Skip to content

Releases: pointfreeco/swift-snapshot-testing

1.11.1

29 Jun 14:09
dc46eeb
Compare
Choose a tag to compare

What's Changed

Full Changelog: 1.11.0...1.11.1

1.11.0

20 Jan 20:29
cef5b3f
Compare
Choose a tag to compare

What's Changed

  • Added: Image paths in Xcode XCTest output are now clickable (thanks @RufusMall, #675).
  • Fixed: Silenced SPM warnings by excluding snapshots and fixtures in Package manifest (thanks @valeriyvan, #684).
  • Fixed: 1.10.0 erroneously bumped platform requirements. This release reverts compatibility to align with previous versions (#698).
  • Infrastructure: Fixed Ubuntu CI by locking version (#685).

New Contributors

Full Changelog: 1.10.0...1.11.0

1.10.0

22 Sep 01:08
f29e201
Compare
Choose a tag to compare

Changes that may affect your build requirements

  • The package name has been changed from SnapshotTesting to swift-snapshot-testing, to better reflect community naming conventions (#555). This may require you to update any Package.swift files that depend on Snapshot Testing.
  • Support for CocoaPods and Carthage has been obsoleted. No new releases will be available on those platforms, starting with 1.10.0. Please use the Swift Package Manager to depend on Snapshot Testing.
  • Snapshot Testing now requires Swift 5.5+, as well at iOS 13+, macOS 10.15+, tvOS 13+, and watchOS 6+.

Changes that may affect snapshot format/output

Warning: The following updates change how a strategy may output a snapshot, causing existing snapshot suites to fail. When upgrading, please rerecord your failing snapshots and audit the changes.

  • Fixed: A UIViewController strategy was not passing along the correct trait collection (thanks @arnopoulos, #554).
  • Fixed: iPhone XS Max portrait configuration was not applying base traits (thanks @imvm, #417)
  • Fixed: URLRequest strategy now sorts query items for more consistent diffing (thanks @mihai8804858, #491).
  • Removed: GLKView is no longer supported (thanks @jpsim, #507).

Everything else

  • Added: Image-based strategies have a new perceptualPrecision option, which can be used to support snapshot tests across Intel and M1 devices. Along for the ride is a 90+% speed improvement to the strategies (thanks @ejensen, #628).
  • Added: Windows support, CI (thanks @MaxDesiatov, #532).
  • Added: Failure messages now include the snapshot name, if given (thanks @calda, #547).
  • Added: iPhone 13 configs (thanks @luispadron, #603).
  • Added: iPad 9.7" and iPad 10.2" configs (thanks @skols85, #405).
  • Added: iPhone 12 and iPhone 12 Pro Max configs(thanks @imvm, #418).
  • Added: Snapshotting.json for Any value (thanks @NachoSoto, #552).
  • Added: Newly-recorded snapshots are now attached to the test run (thanks @marcelofabri, #586).
  • Fixed: the UIImage strategy was using the device scale instead of the scale of the given images (thanks @codeman9, #472).
  • Fixed: the UIImage strategy now compares image contexts using the same colorspace (thanks @dflems, #446).
  • Fixed: the WebView strategy no longer overrides the delegate (thanks @teameh in #443).
  • Fixed: Patched a leak when running tests in a host application (thanks @llinardos, #511).
  • Fixed: False positive when asserting reference image with empty image (thanks @nuno-vieira, #453).
  • Fixed: watchOS compilation (thanks @aydegee, #579).
  • Fixed: Support for repeatedly running tests (thanks @krzysztofpawski, #585).
  • Infrastructure: Add swift-snapshot-testing-stitch to plugins list (thanks @Sherlouk, #483)
  • Infrastructure: Document diff tool configuration.
  • Infrastructure: README updates (thanks @MaatheusGois, @gohanlon), documentation fixes (thanks @heckj, @valeriyvan).
  • Infrastructure: Added GitHub issue templates (#556).
  • Infrastructure: Add SnapshotTestingHEIC to plugins list (thanks @alexey1312, #561).

New Contributors

Full Changelog: 1.9.0...1.10.0

1.9.0

27 Apr 20:55
f8a9c99
Compare
Choose a tag to compare
  • Added: publicized data snapshotting strategy (thanks @regexident).
  • Speed up NSImage comparison (thanks @finestructure, @JaapWijnen).
  • Fixed: enabled testing search paths (thanks @thedavidharris).
  • Infrastructure: links for AccessibilitySnapshot and AccessibilitySnapshotColorBlindness (thanks @Sherlouk).

1.8.2

20 Aug 19:45
c466812
Compare
Choose a tag to compare
  • Rename SnapshotTesting.record to SnapshotTesting.isRecording to avoid clash with XCTestCase's new record method (thanks @xavierLowmiller).
  • Fix UIApplication selector to return the application as expected (thanks @mstultz).
  • Fix key window warning (thanks @tinder-maxwellelliott)

1.8.1

19 Jun 21:03
2fd9135
Compare
Choose a tag to compare
  • Change minimum iOS version from iOS 10 to 11 to fix SwiftUI linking problems (thanks @thedavidharris).

1.8.0

12 Jun 13:33
Compare
Choose a tag to compare
  • 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

07 Feb 22:33
1148823
Compare
Choose a tag to compare

This release fixes a bug introduced in the Xcode 11.4 beta with SPM and Swift 5.2.

SwiftPM Tools 5.0 Support

15 Dec 15:28
12c6a7c
Compare
Choose a tag to compare

This minor release introduces backwards compatibility for SwiftPM Tools @ 5.0.

1.7.0

11 Dec 22:02
Compare
Choose a tag to compare

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!