Skip to content

Conversation

aydegee
Copy link
Contributor

@aydegee aydegee commented Mar 1, 2022

Include watchOS in the availability check for sortedKeys allowing the library to compile under watchOS.

This wouldn’t normally be necessary given that watchOS snapshots are not currently supported.

However Xcode seems to try and compile test targets when generating SwiftUI previews and so those targeting Apple Watch weren’t rendering.

This was making it difficult to work with SwiftUI previews inside modules containing views intended for both phone and watch platforms.

@dani-gavrilov
Copy link

I also faced the need for these changes. Snapshots are an iOS-only dependency and I can run tests for watchOS without any issues. But somehow the SwiftUI preview for watchOS requires these changes.

It would be nice if someone could review and merge it.

@stephencelis stephencelis merged commit 567c66a into pointfreeco:main Jun 6, 2022
@stephencelis
Copy link
Member

Thanks!

niil-qb pushed a commit to quickbit/swift-snapshot-testing that referenced this pull request Feb 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants