137 Followers
78 Following
856 Posts
iOS software engineer. I make FourSix Coffee App in my spare time.
pronounshe/him/his
FourSix Coffee Apphttps://foursixcoffeeapp.com

SwiftUI previews offer a fast, practical way to see the output of our view code. But did you know you can also use them to check accessibility-related UI changes including Dynamic Type, localisation, and system accessibility settings, all without needing a physical device.

https://mobilea11y.com/blog/swiftui-preview-testing/

#accessibility #a11y #ios #iosdevelopment #swiftui

Checking accessibility with SwiftUI Previews

SwiftUI previews offer a fast, practical way to see the output of our view code. But did you know you can also use them to test accessibility-related UI changes including Dynamic Type, localisation, and system accessibility settings, all without needing a physical device.

Mobile A11y

Discovered the most annoying #swiftui bug where a child sheet's state is completely reset when backgrounding the app. Nothing fancy, basic view setup. Just requires a very specific hierarchy. Submitted feedback FB22482861. Details in gist.

https://gist.github.com/jonduenas/41fa6732320ac3a852ce08889cfaaec3

I’m gonna start a conversion therapy camp for straight cis kids to turn them gay/trans and see how quickly this suddenly isn’t about “free speech”.
115 hours in and I’m just now starting act 3 of Baldur’s Gate 3 🫠 Hopefully I can wrap this up before Saros comes out next month.
I bought an iPad and decided I wanted to start learning to draw. Just felt the need to try some new creative outlet. Best of all it’s just a hobby for me. Not to turn into some side gig or internet clout or anything. Probably won’t share any of it because I’ll probably suck for a real long time too, but that’s ok.
@mattiem If Swift Testing’s built in timeout mechanism works, it wouldn’t be so bad. I just worry about leaving CI hanging forever.

@mattiem I think it’s potentially a fundamental issue with Swift Testing especially with parallel testing and how a test’s runtime may not reflect clock time given how they all interleave at suspensions, especially if all MainActor. Just a theory though.

That does make me wonder, with AsyncStream, there’s no built in timeout either. So what happens if a test fails to call the closure?

@mattiem We’ve been using this https://github.com/dfed/swift-testing-expectation

But it’s not very reliable sometimes with timeouts, especially on CI. Had to set 10 second timeouts as a minimum.

@mattiem This has been a huge pain point for us. Calling some sync function that fires a fire-and-forget async thing and we can’t await in the test. So XCTestExpectation is the only reasonable option which doesn’t exist in Swift Testing. If this covers that, then I’m definitely going to give it a try.