diff --git a/Example/OpenSwiftUIUITests/Layout/Geometry/GeometryReaderUITests.swift b/Example/OpenSwiftUIUITests/Layout/Geometry/GeometryReaderUITests.swift index 38563db42..a2783e0b2 100644 --- a/Example/OpenSwiftUIUITests/Layout/Geometry/GeometryReaderUITests.swift +++ b/Example/OpenSwiftUIUITests/Layout/Geometry/GeometryReaderUITests.swift @@ -8,7 +8,7 @@ import Testing @MainActor @Suite(.snapshots(record: .never, diffTool: diffTool)) struct GeometryReaderUITests { - @Test + @Test(.bug("https://github.com/OpenSwiftUIProject/OpenSwiftUI/issues/474")) func centerView() { struct ContentView: View { var body: some View { @@ -24,6 +24,15 @@ struct GeometryReaderUITests { } } openSwiftUIAssertSnapshot(of: ContentView()) + #if os(iOS) + #if OPENSWIFTUI + withKnownIssue { + openSwiftUIAssertSnapshot(of: ContentView(), as: .image) + } + #else + openSwiftUIAssertSnapshot(of: ContentView(), as: .image) + #endif + #endif } @Test diff --git a/Example/OpenSwiftUIUITests/Layout/Modifier/InsetViewModifierUITests.swift b/Example/OpenSwiftUIUITests/Layout/Modifier/InsetViewModifierUITests.swift new file mode 100644 index 000000000..727f7193c --- /dev/null +++ b/Example/OpenSwiftUIUITests/Layout/Modifier/InsetViewModifierUITests.swift @@ -0,0 +1,25 @@ +// +// InsetViewModifierUITests.swift +// OpenSwiftUIUITests + +import Testing + +@MainActor +struct InsetViewModifierUITests { + @Test(.bug("https://github.com/OpenSwiftUIProject/OpenSwiftUI/issues/511")) + func safeAreaPaddingWithEdgeInsets() { + struct ContentView: View { + var body: some View { + Color.red + .safeAreaPadding(.init(top: 10, leading: 20, bottom: 30, trailing: 40)) + } + } + #if OPENSWIFTUI + withKnownIssue { + openSwiftUIAssertSnapshot(of: ContentView()) + } + #else + openSwiftUIAssertSnapshot(of: ContentView()) + #endif + } +}