testing-pyramid
Installation
SKILL.md
Testing Pyramid
Structure
Unit Tests — fast domain logic checks without a Spring context
Slice Tests — focused web or persistence infrastructure checks
Integration Tests — cross-boundary behavior with real dependencies
Unit Tests — Services
Choose the mix by risk, not a fixed percentage. Use real database/Redis tests for concurrency, serialization and transaction semantics that mocks cannot establish. Preserve the project's JUnit/AssertJ and mocking conventions; changing assertion libraries is not a correctness fix.
@ExtendWith(MockitoExtension.class)
class OrderServiceTest {