WBF Academy
Test-Driven Development in Swift

Test-Driven Development in Swift

Intermediate

Write Swift you can change without fear. This intermediate course teaches test-driven development the way it actually works on a real codebase: you write a failing test first, make it pass with the simplest thing possible, then refactor while the suite stays green. It is built on Swift Testing, the modern framework with @Test, #expect, #require, suites, traits, and parameterized tests, and it also covers XCTest where you still need it, for UI and performance tests and for migrating an existing suite. You will go well past the basics: designing types that are testable in the first place through dependency injection and protocol seams, building stubs, spies and fakes without a mocking framework, testing async/await, actors and MainActor code deterministically instead of with sleeps, and taming legacy code with characterization tests. You will also learn what TDD does not solve, why chasing 100% coverage makes suites worse, and how to keep tests fast and free of flakiness. Assumes you already write Swift comfortably. By the end, tests will be how you design code, not a chore you do afterwards.

📋 5 tracks ❓ 350 questions 💡 35 tips 🎬 15 videos ⏱ ~8h

Course content

Certification Exam

🏆

Certification Exam

Test-Driven Development in Swift

30
Questions
45m
Time Limit
% 70%
To Pass

🔒 Unlock the exam

🎬 Watch 80% of the videos 0% / 80%
❓ Answer 80% of the practice questions 0% / 80%

Complete the requirements above to unlock the exam

🏆

Certification Exam

Test-Driven Development in Swift

#

30 Questions

All difficulty levels

45 Minutes

Auto-submits when time expires

%

70% to Pass

Earn your certification badge

No Going Back

Once you answer, you move forward

Tips

See all