Universal principles for writing good tests. These apply regardless of framework, language, or repo — discover and follow your repo's specific testing tools, commands, and conventions from its project configuration, contributor guides, existing test files, CI/CD config, and any repo-level AI skills or rules.
Tests verify behavior through public interfaces, not implementation details. Code can change entirely; tests shouldn't break unless behavior changed.
Good tests exercise real code paths through public APIs. They describe what the system does, not how. A good test reads like a specification — "user can checkout with valid cart" tells you exactly what capability exists. These tests survive refactors because they don't care about internal structure.
Universelle testgetriebene Entwicklungsmethodik und Testdesign-Handwerk. Hintergrundwissen zum Schreiben verhaltensorientierter Tests, Mocking-Strategie, vertikales Schneiden und Ausführung von Leuchtspurgeschossen. Wird beim Schreiben von Tests automatisch geladen während der Implementierung, Review-Feedback oder eigenständiges Test-Authoring. Auslöser: Tests schreiben, Testdesign, Mocking-Strategie, Testqualität, Verhaltenstests, Integrationstests, Test-First, Rot-Grün-Refaktor. Quelle: inkeep/team-skills.