A Web Application that acts as a car rental company. The user can view the available cars, then pay for the access to the selected package, and finally pick up his car. The main reason for me to create this application was to learn Junit and Mockito testing.
- Java 17
- Spring Boot v2.5.5
- Maven v3.8.2
- MySQL Community Server v8.0.27
- Spring Data JPA
- Spring Web MVC
- Spring Security with JWT
- Lombok
- JUnit 5
- Mockito
For building and running the application you need:
- Install MySQL
- Execute command
git clone https://github.com/Tomasz3976/car-rental-project.git
- Execute command
cd car-rental-project
- Configure datasource in main/resources/application.yml
spring:
datasource:
url: jdbc:mysql://localhost:3306/carrentaldb
username: username
password: password
- Configure datasource in test/resources/application.yml
spring:
datasource:
url: jdbc:mysql://localhost:3306/carrentaltestdb
username: username
password: password
- Execute command
mvn clean install
- Execute command
mvn spring-boot:run
- The server is running on localhost:8080
Role | Username | Password |
---|---|---|
User | user | user |
Manager | manager | manager |
Admin | admin | admin |
To explore documentation, run the application and go to http://localhost:8080/swagger-ui.html