Swift Wants Your Tests in the Same File as Your Code. The Hard Part Is Keeping Them Out of Your Binary.
A new Swift Testing pitch, 'Colocated Tests', lets a SwiftPM library target hold @Test functions right next to the code they test, including access to private members. Here's how the proposed @available(Testing) domain keeps test code out of release builds, the open questions on build times and linking, and what it means for iOS app projects.
Your Set Iterates in a Different Order Every Launch. That's Not a Bug, It's a Security Feature.
Swift randomizes its hash seed on every process launch, so Set and Dictionary iteration order changes between runs. Here's why that exists, the three places it silently breaks your app, and how to get stable order without giving up the hash table.
Swift Testing Is About to Turn Off the One Field Your CI Script Actually Reads
ST-0029 was accepted into Swift Testing on September 13, adding structured issue metadata to the JSON event stream. The quiet part: the human-readable messages field becomes opt-in, off by default. Here's what that means for anyone parsing test output in CI.
Telling Your Coding Agent to 'Use TDD' Doesn't Work. A New Study Shows Why.
A rigorous study of 26 testing techniques given to AI coding agents finds that naming a technique in your prompt barely changes what they actually do. Here's what that means for Swift and SwiftUI.
Swift Testing Runs Your Suite in Parallel. That Static Var You Swap for DI Is a Race Condition.
Swift Testing parallelizes tests by default, in the same process. A huge number of Swift codebases — BrewLog's AppIntents suite included — still inject test dependencies by mutating a global static var. ST-0026 proposes a .taskLocal trait to fix it properly. Here's the real bug, the real code, and where the proposal stands.
Swift Just Got a Real Timeout API. Here's What We've All Been Duct-Taping Instead.
SE-0526 withDeadline was accepted into Swift on July 30, 2026 — a real, composable, absolute-time-limit API for async operations. I found the exact gap it fills in a real app's networking layer, fixed it today's way with a TaskGroup race, and lined it up against what withDeadline will let me delete once it ships.
TDD for SwiftUI: A Red-Green-Refactor Workflow That Isn't Academic
Day 21 of the 30-day iOS series. I went looking for a BrewLog feature to drive test-first and found a real bug already shipped: the Streak stat has been hardcoded to zero since day one. Here's the actual red-green-refactor session that fixed it.
Swift Testing Framework: Why You Should Migrate from XCTest
Day 20 of the 30-day iOS series. @Test, #expect, parametrized tests, traits, and a side-by-side comparison on a real BrewLog test file. Plus: the one thing XCTest still does that Swift Testing doesn't.