Che cos'è swift-testing?
Da utilizzare quando si scrivono test con Swift Testing (@Test, Fonte: johnrogers/claude-swift-engineering.
Da utilizzare quando si scrivono test con Swift Testing (@Test,
Installa rapidamente la skill AI swift-testing nel tuo ambiente di sviluppo tramite riga di comando
Fonte: johnrogers/claude-swift-engineering.
Swift Testing replaces XCTest with a modern macro-based approach that's more concise, has better async support, and runs tests in parallel by default. The core principle: if you learned XCTest, unlearn it—Swift Testing works differently.
| #expect(expression) | Soft check — continues on failure. Use for most assertions. | | #require(expression) | Hard check — stops test on failure. Use for preconditions only. |
| XCTAssert(expr) | #expect(expr) | | XCTAssertEqual(a, b) | #expect(a == b) | | XCTAssertNil(a) | #expect(a == nil) | | XCTAssertNotNil(a) | #expect(a != nil) | | try XCTUnwrap(a) | try #require(a) | | XCTAssertThrowsError | #expect(throws: ErrorType.self) { } | | XCTAssertNoThrow | #expect(throws: Never.self) { } |
Da utilizzare quando si scrivono test con Swift Testing (@Test, Fonte: johnrogers/claude-swift-engineering.
Campi e comandi stabili per citazioni AI/ricerca.
npx skills add https://github.com/johnrogers/claude-swift-engineering --skill swift-testingDa utilizzare quando si scrivono test con Swift Testing (@Test, Fonte: johnrogers/claude-swift-engineering.
Apri il tuo terminale o strumento da riga di comando (Terminal, iTerm, Windows Terminal, ecc.) Copia ed esegui questo comando: npx skills add https://github.com/johnrogers/claude-swift-engineering --skill swift-testing Dopo l'installazione, la skill verrà configurata automaticamente nel tuo ambiente AI di coding e sarà pronta all'uso in Claude Code, Cursor o OpenClaw
https://github.com/johnrogers/claude-swift-engineering