This repository contains a backend system for managing doctor appointment bookings. The system is designed for a single doctor and adheres to modular monolithic architecture principles, implementing four key modules:
- Doctor Availability (Traditional Layered Architecture)
- Appointment Booking (Clean Architecture)
- Appointment Confirmation (Simple Architecture)
- Doctor Appointment Management (Hexagonal Architecture)
- Add Slots: Add new time slots for the doctor, including slot details like time, and cost.
- List Slots: View all available and reserved slots for the doctor.
- View Slots: Patients can view all available slots.
- Book Appointment: Patients can book an appointment for a specific slot.
- Send Notification: Send a confirmation notification to the patient and doctor upon successful booking.
- View Appointments: Doctors can view their upcoming appointments.
- Manage Appointments: Doctors can mark appointments as completed or cancel them.
The system follows a modular monolithic architecture, with each module designed independently to ensure separation of concerns and maintainability.
-
Doctor Availability Module
- Architecture: Traditional Layered
- Layers: API → Business → Data
-
Appointment Booking Module
- Architecture: Clean Architecture
- Layers:
- API: Controllers
- Application: Use Cases
- Domain: Business Rules
- Infrastructure: Database and external dependencies
-
Appointment Confirmation Module
- Architecture: Simple architecture
- Implementation: Straightforward logging of notifications upon booking confirmation.
-
Doctor Appointment Management Module
- Architecture: Hexagonal Architecture
- Core: Domain logic for managing appointments
- Shell: External interaction
- Install the .NET SDK (8.0 or higher).
- Clone the Repository:
git clone https://github.com/MostafaAE/clinicore-modulith
- Navigate to the Project Directory:
cd .\clinicore-modulith\src\Bootstrapper\CliniCore.Bootstrapper
- Run the Application:
dotnet run --project CliniCore.Bootstrapper.csproj
- Access the API:
http://localhost:5050/swagger/index.html
The system is thoroughly tested to ensure reliability and accuracy. Both unit tests and integration tests are implemented, with a strong emphasis on covering all modules and edge cases.
- Comprehensive Coverage: All four modules are fully tested, including business logic, API endpoints, and inter-module integration.
- Edge Cases: Focused extensively on testing edge scenarios to ensure the system handles unexpected or extreme inputs gracefully.
- Mocking: Dependencies are mocked using Moq to isolate and test components effectively.
To execute all unit and integration tests:
dotnet test- .NET: Core framework for the backend system
- SQLite: As the database engine
- Entity Framework: ORM for the database
- xUnit: Unit and integration testing
- Fluent Assertions: For expressive and readable assertions in tests
- Moq: For mocking dependencies in tests
- AutoFixture: For generating test data


