Skip to content
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

Add configure block to allow input customisation #4

Closed
Sherlouk opened this issue Jul 19, 2021 · 0 comments · Fixed by #5
Closed

Add configure block to allow input customisation #4

Sherlouk opened this issue Jul 19, 2021 · 0 comments · Fixed by #5

Comments

@Sherlouk
Copy link
Owner

The idea of the library is to allow users to stitch multiple variants of the same value into a single image. This is possible using the different traits (such as dynamic text size or user interface style) or image strategies (such as device size).

However, it doesn't allow you to apply customisations to the view which are done at a custom class level. To be clearer, we should add the ability to change variables on the view itself for each test in the stitch.

assertSnapshot(matching: vc, as: .stitch(strategies: [
  ("iPhone 8", .image(on: .iPhone8), configure: { $0.theme = .light }),
  ("iPhone 8 Plus", .image(on: .iPhone8Plus), configure: { $0.theme = .dark }),
]))
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 a pull request may close this issue.

1 participant