diff --git a/SnapshotTests/SnapshotTestCase.swift b/SnapshotTests/SnapshotTestCase.swift index d6d46b3e2..6c9ddd635 100644 --- a/SnapshotTests/SnapshotTestCase.swift +++ b/SnapshotTests/SnapshotTestCase.swift @@ -189,3 +189,38 @@ extension Snapshotting where Value == UIView, Format == UIImage { ) } } + +extension Snapshotting where Value == UIViewController, Format == UIImage { + static var extra3LargeFontStrategyLandscape: Self { + let traits = UITraitCollection(traitsFrom: [ + .init(forceTouchCapability: .available), + .init(layoutDirection: .leftToRight), + .init(preferredContentSizeCategory: .medium), + .init(userInterfaceIdiom: .phone), + .init(horizontalSizeClass: .regular), + .init(verticalSizeClass: .compact), + .init(preferredContentSizeCategory: .accessibilityExtraExtraExtraLarge) + ]) + let safeArea: UIEdgeInsets = .init(top: 0, left: 47, bottom: 21, right: 47) + let size: CGSize = .init(width: 844, height: 390) + let viewImageConfig: ViewImageConfig = .init(safeArea: safeArea, size: size, traits: traits) + + return Self.image(on: viewImageConfig) + } + + static var imageLandscape: Self { + let traits = UITraitCollection(traitsFrom: [ + .init(forceTouchCapability: .available), + .init(layoutDirection: .leftToRight), + .init(preferredContentSizeCategory: .medium), + .init(userInterfaceIdiom: .phone), + .init(horizontalSizeClass: .regular), + .init(verticalSizeClass: .compact) + ]) + let safeArea: UIEdgeInsets = .init(top: 0, left: 47, bottom: 21, right: 47) + let size: CGSize = .init(width: 844, height: 390) + let viewImageConfig: ViewImageConfig = .init(safeArea: safeArea, size: size, traits: traits) + + return Self.image(on: viewImageConfig) + } +}