Approach to adoption of Swift Testing

Currently Swift Testing has much less features than XCTest, so the adoption will be very slow from our side. Notable features we miss are UI tests, performance tests and attachments.

I did not want to create many issues in Swift Testing GitHub project as lots of these shortcoming are most probably tracked internally (I can see lots of references to radars in GitHub issues.)

So, my question is: Is it a good idea to wait with wider adoption or should we experiment with other tools like swift Benchmarks?

One more thing, link from Swift Testing Overview to Apple forums leads to non-existing tag, so it does not exactly invite a discussion.

So, my question is: Is it a good idea to wait with wider adoption or should we experiment with other tools like swift Benchmarks?

We recommend following the model of the "testing pyramid", in which the bottom of the pyramid represents your more narrowly-scoped unit tests which run in process. There tend to be the largest number of these kinds of tests, and they are a great candidate to use Swift Testing.

In the middle of the pyramid are integration-style tests which validate the interaction between two or more components. There are typically fewer of those, but you can generally write them using Swift Testing too.

At the top of the pyramid are the most widely-scoped tests which test your app end-to-end, and even perform UI automation. For this category, which is typically the smallest in number, continue using XCTest and its UI automation APIs. Performance tests don't map neatly onto the "pyramid" analogy but there's also typically few of them, and we recommend continuing to use XCTest for those.

Migrating eligible tests to Swift Testing will allow them to realize its benefits earlier, even though not every test will use the same framework.

One more thing, link from Swift Testing Overview to Apple forums leads to non-existing tag, so it does not exactly invite a discussion.

This broken link has been resolved, and these Forums now have a dedicated Swift Testing tag! Thank you for pointing this out.

Approach to adoption of Swift Testing
 
 
Q