An Android application built in Kotlin using Jetpack Compose, following Clean Architecture and MVVM principles. The app allows users to be added, stored locally using Room, and displayed in a list. Input validation, modern UI, and a layered architecture ensure scalability and testability.
-
Add User Screen
- Fields: Name, Email, Gender
- Validations for required fields and email format
- Gender radio group
- Error messages with real-time feedback
-
User List Screen
- Displays all saved users using
LazyColumn(Jetpack Compose) - Each item shows name, email, gender, and initials avatar
- Displays all saved users using
-
Offline Storage
- Users are saved locally using Room Database
- Data persists after app closes
-
Architecture
- Clean Architecture separation: Data, Domain, Presentation
- MVVM pattern with ViewModels and UseCases
-
Dependency Injection
- Uses Hilt to inject ViewModels, Repositories, DAOs
-
UI & Navigation
- Built using a mix of Jetpack Compose and XML
- Navigation component for screen routing
-
Testing
- Unit tests for UseCases, Validators, Repositories, ViewModels
- UI tests for Compose screens
Follows Clean Architecture with layered separation:
Presentation
├── adduser
├── userslist
├── navigation
│
Domain
├── UseCases
├── Models
├── Validation
├── Mapper
│
Data
├── Room Entities & DAO
├── Repository Implementation
Core
┌──────────────────────────────┐
│ Presentation │
│ (Jetpack Compose UI) │
│ ─ ViewModel (State) │
└──────────────────────────────┘
│
▼
┌───────────────────────────────┐
│ Domain │
│ ┌───────────────────────────┐ │
│ │ Use Cases (Business Rules) │
│ └───────────────────────────┘ │
│ ┌──────────────────────────┐ │
│ │ Models (Pure) │ │
│ └──────────────────────────┘ │
│ Mappers │
└───────────────────────────────┘
│
▼
┌──────────────────────────────┐
│ Data │
│ ┌──── Repository Impl ─────┐ │
│ │ - Room (DAO) │ │
│ └──────────────────────────┘ │
└──────────────────────────────┘
src/
└── main/
├── java/com/madarsoft/task/
│ ├── core/ # Base components and utilities
│ ├── data/ # Room DB, DAO, repository
│ ├── domain/ # UseCases, validation, models
│ ├── di/ # Hilt modules
│ └── presentation/ # UI Screens and ViewModels
└── res/
├── layout/ # (for using XML components)
└── values/ # Themes, strings, colors
- Jetpack Compose – Declarative UI framework
- Room – Local database
- Hilt – Dependency injection
- Coroutines – Asynchronous operations
- Navigation Component – Screen transitions
- ViewModel & LiveData – Lifecycle-aware state management
- WorkManager – Background tasks
- Testing:
JUnit,Mockk,Truth,Mockitofor unit testsEspresso,Compose UI Testfor UI testing
- ✅ UseCase tests
- ✅ Validator logic tests
- ✅ Repository behavior tests
- ✅ ViewModel logic
- ✅ Instrumented UI tests for Compose screens
find apk from url https://drive.google.com/drive/folders/1g2WPXgmOaib_sj83Rs93TfmzKlCYIVCQ?usp=sharing
- Android Studio Narwhal
- Kotlin 2.2.0
- Min SDK: 24
- Gradle (Kotlin DSL)
Ali hrhera
Email: alihrhera1@gmail.com
The project follows a clear and structured Git branching strategy to maintain clean collaboration and code quality.
develop: Main integration branch where all completed features are merged.feature/users-list: Responsible for implementing the user list screen.feature/add-users: Handles the add user feature.feature/create-core: Sets up core business logic and base classes.feature/create-local-db: Configures the Room database and local storage layer.
All feature branches were merged into develop via Pull Requests (PRs) to ensure code review and maintain stability.
This project loosely follows the Git Flow model to support scalability and teamwork.

