`swift test` tries to build all targets instead of just those needed for testing

For some projects it's even worse: take, for example, swift-cross-ui. You will never be able to build every single target on one machine because some targets require Apple-only dependencies (e.g. AppKit) while others require the Windows SDK. So simply running swift test will never work.

1 Like