swift-testing

Installation
SKILL.md

Swift Testing Framework: Basics

Guidance for starting with Swift Testing (Testing framework) and writing clear, macro-driven tests.

Core Concepts

  • Import Testing to unlock macros; tests are plain functions annotated with @Test.
  • Name tests freely; use @Test("Display Name") to set the navigator title.
  • #expect is the primary assertion; pass a boolean expression to assert truthy outcomes.
  • Async/throwing tests are supported via async/throws on the test function.
  • Works alongside XCTest in the same project.

Example: Simple Test

import Testing

func add(_ a: Int, _ b: Int) -> Int { a + b }
Installs
7
GitHub Stars
18
First Seen
Jan 24, 2026
swift-testing — mintuz/claude-plugins