A fun and colorful 2048 puzzle game with a fruit theme, built using Jetpack Compose. Merge matching fruits to reach the highest score and unlock new fruit tiles! 🍓🍍
- 🍎 Classic 2048 gameplay with a fruit twist
- 🎨 Modern UI built entirely with Jetpack Compose
- 🌗 Light & Dark theme support
- 🔄 Undo move support
- 🏆 Best score saved locally
- 📱 Smooth animations and responsive controls
- Swipe in any direction (⬆️⬇️⬅️➡️)
- Merge two identical fruits to create a bigger fruit
- Each merge increases your score
- The game ends when no more moves are possible
- UI: Jetpack Compose, Material 3
- Language: Kotlin, Coroutines & StateFlow
- Dependency Injection: Dagger Hilt
- Local Persistence: Room Database
- Testing: JUnit4, Robolectric, Compose UI Test, Turbine, UIAutomator
- Performance & Profiling: Jetpack Macrobenchmark (
StartupTimingMetric,FrameTimingMetric), Baseline Profile Gradle Plugin
The project maintains test coverage across unit, UI, and end-to-end layers:
- Unit & Game Engine Tests: Verifies grid shifting, fruit tile merging rules, score calculation, random tile spawning, and game-over conditions using deterministic test fakes.
- State & Flow Tests: Uses Turbine to assert reactive
StateFlowemissions and Room persistence transitions. - Component & UI Tests: Uses Robolectric and Compose testing APIs to verify board rendering, gesture handling, and dialog states without requiring an emulator.

