android-tdd - Android TDD Testing Patterns
Android/Kotlin/KMP code TDD with three-tier test model, fake-first strategy, coroutine testing, and Compose UI testing
Tags
Updated: 2026-05-11Capabilities
Typical Inputs
Typical Outputs
What this skill does
- create Fake implementation
- write unit test
- write integration test
- write instrumented test
- verify ViewModel state
- verify UI state
- check UI element displayed
- configure test rule
- test Hilt dependency
- verify StateFlow
- verify SharedFlow
- capture UI screenshot
- use Turbine for flow testing
- use Robolectric for integration testing
- use Roborazzi for screenshot testing
- match assertions with Kotlin test
Inputs
- Android project source code
- Kotlin/KMP test source code
- Fake test implementation
- test rule
- test state input
- screenshot test configuration
- test assertion library
Outputs
- test execution result
- test report
- screenshot capture
Requirements
- superpowers:test-driven-development skill
- Android development environment
- Kotlin development environment
- Gradle build tool
- kotlinx-coroutines-test library
- AndroidX test library
- Hilt testing library
- Roborazzi library
- Jetpack Compose UI testing library
